Re: UI tests require modifying homedir

Pranav Kant [2014-02-28 21:17 +0530]:
Moreover, we can copy some of the test-data into homedir and then clean it
up after tests complete. Continous do not have any problems with that but
then running 'make check' on users local machine would break the user's
homedir and some users might not like that at all.

Indeed you should write tests with the assumption in mind that they
might fail or crash at any point, so the "clean up afterwards"
approach is only generally useful for "real" temporary stuff in /tmp
where some clutter doesn't matter much.

For such kind of test data I found it more robust and even easier to
create a temporary dir with the desired contents, point
$HOME and possibly $XDG_{CONFIG,DATA,*}_HOME to that, and then run the
application. For example



Martin Pitt                        |
Ubuntu Developer (  | Debian Developer  (

[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]