summaryrefslogtreecommitdiffstats
path: root/test/environment/output.exp
diff options
context:
space:
mode:
authorLibravatar netblue30 <netblue30@yahoo.com>2016-06-13 12:04:35 -0400
committerLibravatar netblue30 <netblue30@yahoo.com>2016-06-13 12:04:35 -0400
commit3cc86927c990f85326d4b6f6b8b9d8ee9d8613e5 (patch)
tree10aa4fa9e2827a08df2441b1442f40aeba4a6855 /test/environment/output.exp
parentconfigure.ac fixes (diff)
downloadfirejail-3cc86927c990f85326d4b6f6b8b9d8ee9d8613e5.tar.gz
firejail-3cc86927c990f85326d4b6f6b8b9d8ee9d8613e5.tar.zst
firejail-3cc86927c990f85326d4b6f6b8b9d8ee9d8613e5.zip
testing
Diffstat (limited to 'test/environment/output.exp')
-rwxr-xr-xtest/environment/output.exp65
1 files changed, 65 insertions, 0 deletions
diff --git a/test/environment/output.exp b/test/environment/output.exp
new file mode 100755
index 000000000..10c325832
--- /dev/null
+++ b/test/environment/output.exp
@@ -0,0 +1,65 @@
1#!/usr/bin/expect -f
2
3set timeout 10
4spawn $env(SHELL)
5match_max 100000
6
7send -- "rm -f logfile*\r"
8sleep 1
9puts "\n"
10
11send -- "firejail --output=logfile -- ./output.sh\r"
12expect {
13 timeout {puts "TESTING ERROR 1\n";exit}
14 "20000"
15}
16expect {
17 timeout {puts "TESTING ERROR 1.1\n";exit}
18 "60000"
19}
20expect {
21 timeout {puts "TESTING ERROR 1.2\n";exit}
22 "100000"
23}
24expect {
25 timeout {puts "TESTING ERROR 1.3\n";exit}
26 "120000"
27}
28expect {
29 timeout {puts "TESTING ERROR 1.4\n";exit}
30 "14999"
31}
32sleep 2
33puts "\n"
34
35
36set timeout 2
37send -- "ls -al logfile*\r"
38expect {
39 timeout {puts "TESTING ERROR 2\n";exit}
40 "logfile"
41}
42expect {
43 timeout {puts "TESTING ERROR 3\n";exit}
44 "logfile.1"
45}
46expect {
47 timeout {puts "TESTING ERROR 4\n";exit}
48 "logfile.2"
49}
50expect {
51 timeout {puts "TESTING ERROR 5\n";exit}
52 "logfile.3"
53}
54expect {
55 timeout {puts "TESTING ERROR 6\n";exit}
56 "logfile.4"
57}
58expect {
59 timeout {puts "TESTING ERROR 7\n";exit}
60 "logfile.5"
61}
62after 100
63send -- "rm -f logfile*\r"
64after 100
65puts "\nall done\n"