summaryrefslogtreecommitdiffstats
path: root/test/features/1.8.exp
diff options
context:
space:
mode:
Diffstat (limited to 'test/features/1.8.exp')
-rwxr-xr-xtest/features/1.8.exp71
1 files changed, 71 insertions, 0 deletions
diff --git a/test/features/1.8.exp b/test/features/1.8.exp
new file mode 100755
index 000000000..514dd3b81
--- /dev/null
+++ b/test/features/1.8.exp
@@ -0,0 +1,71 @@
1#!/usr/bin/expect -f
2#
3# disable /etc/firejail and ~/.config/firejail
4#
5
6set timeout 10
7spawn $env(SHELL)
8match_max 100000
9
10#
11# N
12#
13send -- "touch /var/tmp/somefile\r"
14sleep 1
15send -- "firejail --noprofile\r"
16expect {
17 timeout {puts "TESTING ERROR 0\n";exit}
18 "Child process initialized"
19}
20sleep 1
21
22send -- "ls -l /var/tmp/somefile | wc -l\r"
23expect {
24 timeout {puts "TESTING ERROR 1\n";exit}
25 "0"
26}
27after 100
28send -- "exit\r"
29sleep 1
30
31
32#
33# O
34#
35send -- "firejail --noprofile --overlay\r"
36expect {
37 timeout {puts "TESTING ERROR 2\n";exit}
38 "Child process initialized"
39}
40sleep 1
41
42send -- "ls -l /var/tmp/somefile | wc -l\r"
43expect {
44 timeout {puts "TESTING ERROR 3\n";exit}
45 "0"
46}
47after 100
48send -- "exit\r"
49sleep 1
50
51#
52# C
53#
54send -- "firejail --noprofile --chroot=/tmp/chroot\r"
55expect {
56 timeout {puts "TESTING ERROR 3\n";exit}
57 "Child process initialized"
58}
59sleep 1
60
61send -- "ls -l /var/tmp/somefile | wc -l\r"
62expect {
63 timeout {puts "TESTING ERROR 4\n";exit}
64 "0"
65}
66after 100
67send -- "exit\r"
68sleep 1
69
70
71puts "\nall done\n"