aboutsummaryrefslogtreecommitdiffstats
path: root/test/environment/umask.exp
diff options
context:
space:
mode:
Diffstat (limited to 'test/environment/umask.exp')
-rwxr-xr-xtest/environment/umask.exp41
1 files changed, 41 insertions, 0 deletions
diff --git a/test/environment/umask.exp b/test/environment/umask.exp
new file mode 100755
index 000000000..e93d71bd4
--- /dev/null
+++ b/test/environment/umask.exp
@@ -0,0 +1,41 @@
1#!/usr/bin/expect -f
2
3set timeout 10
4spawn $env(SHELL)
5match_max 100000
6
7send -- "firejail --noprofile\r"
8expect {
9 timeout {puts "TESTING ERROR 0\n";exit}
10 "Child process initialized"
11}
12sleep 1
13
14send -- "umask\r"
15expect {
16 timeout {puts "TESTING ERROR 1\n";exit}
17 "0123"
18}
19after 100
20
21send -- "firejail\r"
22expect {
23 timeout {puts "TESTING ERROR 2\n";exit}
24 "Warning: an existing sandbox was detected"
25}
26after 100
27
28send -- "umask\r"
29expect {
30 timeout {puts "TESTING ERROR 3\n";exit}
31 "0123"
32}
33after 100
34
35send -- "exit\r"
36after 100
37
38send -- "exit\r"
39sleep 1
40
41puts "\nall done\n"