2 # vim:ts=4:sw=4:expandtab
4 # Please read the following documents before working on tests:
5 # • http://build.i3wm.org/docs/testsuite.html
8 # • http://build.i3wm.org/docs/lib-i3test.html
9 # (alternatively: perldoc ./testcases/lib/i3test.pm)
11 # • http://build.i3wm.org/docs/ipc.html
14 # • http://onyxneon.com/books/modern_perl/modern_perl_a4.pdf
15 # (unless you are already familiar with Perl)
17 # Makes sure i3 deletes its temporary directory when exiting.
19 # Bug still in: 4.7.2-186-g617afc6
20 use i3test i3_autostart => 0;
25 font -misc-fixed-medium-r-normal--13-120-75-75-C-70-iso10646-1
28 # ensure XDG_RUNTIME_DIR is not set
29 delete $ENV{XDG_RUNTIME_DIR};
31 my $pid = launch_with_config($config, dont_add_socket_path => 1, dont_create_temp_dir => 1);
32 my $socketpath = get_socket_path(0);
33 my $tmpdir = dirname($socketpath);
35 ok(-d $tmpdir, "tmpdir $tmpdir exists");
37 # Clear the error logfile. The testsuite runs in an environment where RandR is
38 # not supported, so there always is a message about xinerama in the error
40 my @errorlogfiles = <$tmpdir/errorlog.*>;
41 for my $fn (@errorlogfiles) {
42 open(my $fh, '>', $fn);
46 exit_gracefully($pid);
48 ok(! -d $tmpdir, "tmpdir $tmpdir was cleaned up");
50 diag('contents = ' . Dumper(<$tmpdir/*>));