diff options
Diffstat (limited to 'test/environment/output.exp')
-rwxr-xr-x | test/environment/output.exp | 87 |
1 files changed, 0 insertions, 87 deletions
diff --git a/test/environment/output.exp b/test/environment/output.exp deleted file mode 100755 index d175ddae2..000000000 --- a/test/environment/output.exp +++ /dev/null | |||
@@ -1,87 +0,0 @@ | |||
1 | #!/usr/bin/expect -f | ||
2 | |||
3 | set timeout 10 | ||
4 | spawn $env(SHELL) | ||
5 | match_max 100000 | ||
6 | |||
7 | send -- "rm -f logfile*\r" | ||
8 | sleep 1 | ||
9 | puts "\n" | ||
10 | |||
11 | send -- "firejail --output=logfile -- ./output.sh\r" | ||
12 | expect { | ||
13 | timeout {puts "TESTING ERROR 1\n";exit} | ||
14 | "20000" | ||
15 | } | ||
16 | expect { | ||
17 | timeout {puts "TESTING ERROR 1.1\n";exit} | ||
18 | "60000" | ||
19 | } | ||
20 | expect { | ||
21 | timeout {puts "TESTING ERROR 1.2\n";exit} | ||
22 | "100000" | ||
23 | } | ||
24 | expect { | ||
25 | timeout {puts "TESTING ERROR 1.3\n";exit} | ||
26 | "120000" | ||
27 | } | ||
28 | expect { | ||
29 | timeout {puts "TESTING ERROR 1.4\n";exit} | ||
30 | "14999" | ||
31 | } | ||
32 | sleep 2 | ||
33 | puts "\n" | ||
34 | |||
35 | |||
36 | set timeout 2 | ||
37 | send -- "ls -al logfile*\r" | ||
38 | expect { | ||
39 | timeout {puts "TESTING ERROR 2\n";exit} | ||
40 | "logfile" | ||
41 | } | ||
42 | expect { | ||
43 | timeout {puts "TESTING ERROR 3\n";exit} | ||
44 | "logfile.1" | ||
45 | } | ||
46 | expect { | ||
47 | timeout {puts "TESTING ERROR 4\n";exit} | ||
48 | "logfile.2" | ||
49 | } | ||
50 | expect { | ||
51 | timeout {puts "TESTING ERROR 5\n";exit} | ||
52 | "logfile.3" | ||
53 | } | ||
54 | expect { | ||
55 | timeout {puts "TESTING ERROR 6\n";exit} | ||
56 | "logfile.4" | ||
57 | } | ||
58 | expect { | ||
59 | timeout {puts "TESTING ERROR 7\n";exit} | ||
60 | "logfile.5" | ||
61 | } | ||
62 | after 100 | ||
63 | send -- "rm -f logfile*\r" | ||
64 | |||
65 | |||
66 | send -- "firejail --output=../logfile -- ./output.sh\r" | ||
67 | expect { | ||
68 | timeout {puts "TESTING ERROR 8\n";exit} | ||
69 | "invalid output file" | ||
70 | } | ||
71 | after 100 | ||
72 | |||
73 | send -- "firejail --output=/etc -- ./output.sh\r" | ||
74 | expect { | ||
75 | timeout {puts "TESTING ERROR 9\n";exit} | ||
76 | "invalid output file" | ||
77 | } | ||
78 | after 100 | ||
79 | |||
80 | send -- "firejail --output=/etc/firejail/zoom.profile -- ./output.sh\r" | ||
81 | expect { | ||
82 | timeout {puts "TESTING ERROR 10\n";exit} | ||
83 | "the output file needs to be owned by the current user" | ||
84 | } | ||
85 | |||
86 | after 100 | ||
87 | puts "\nall done\n" | ||