diff options
Diffstat (limited to 'test/features/1.2.exp')
-rwxr-xr-x | test/features/1.2.exp | 141 |
1 files changed, 141 insertions, 0 deletions
diff --git a/test/features/1.2.exp b/test/features/1.2.exp new file mode 100755 index 000000000..399e9948b --- /dev/null +++ b/test/features/1.2.exp | |||
@@ -0,0 +1,141 @@ | |||
1 | #!/usr/bin/expect -f | ||
2 | # | ||
3 | # new /proc | ||
4 | # | ||
5 | |||
6 | set timeout 10 | ||
7 | spawn $env(SHELL) | ||
8 | match_max 100000 | ||
9 | |||
10 | # | ||
11 | # N | ||
12 | # | ||
13 | send -- "firejail --noprofile\r" | ||
14 | expect { | ||
15 | timeout {puts "TESTING ERROR 0\n";exit} | ||
16 | "Child process initialized" | ||
17 | } | ||
18 | sleep 1 | ||
19 | |||
20 | send -- "cat /proc/mounts | grep proc\r" | ||
21 | expect { | ||
22 | timeout {puts "TESTING ERROR 1.1\n";exit} | ||
23 | "proc /proc proc" | ||
24 | } | ||
25 | expect { | ||
26 | timeout {puts "TESTING ERROR 1.2\n";exit} | ||
27 | "proc /proc proc" | ||
28 | } | ||
29 | expect { | ||
30 | timeout {puts "TESTING ERROR 1.3\n";exit} | ||
31 | "proc /proc/sys proc" | ||
32 | } | ||
33 | expect { | ||
34 | timeout {puts "TESTING ERROR 1.4\n";exit} | ||
35 | "proc /proc/sysrq-trigger proc" | ||
36 | } | ||
37 | expect { | ||
38 | timeout {puts "TESTING ERROR 1.5\n";exit} | ||
39 | "proc /proc/sys/kernel/hotplug" | ||
40 | } | ||
41 | expect { | ||
42 | timeout {puts "TESTING ERROR 1.6\n";exit} | ||
43 | "proc /proc/irq proc" | ||
44 | } | ||
45 | expect { | ||
46 | timeout {puts "TESTING ERROR 1.7\n";exit} | ||
47 | "proc /proc/bus proc" | ||
48 | } | ||
49 | after 100 | ||
50 | send -- "exit\r" | ||
51 | sleep 1 | ||
52 | |||
53 | |||
54 | # | ||
55 | # O | ||
56 | # | ||
57 | send -- "firejail --noprofile --overlay\r" | ||
58 | expect { | ||
59 | timeout {puts "TESTING ERROR 2\n";exit} | ||
60 | "Child process initialized" | ||
61 | } | ||
62 | sleep 1 | ||
63 | |||
64 | send -- "cat /proc/mounts | grep proc\r" | ||
65 | expect { | ||
66 | timeout {puts "TESTING ERROR 3.1\n";exit} | ||
67 | "proc /proc proc" | ||
68 | } | ||
69 | expect { | ||
70 | timeout {puts "TESTING ERROR 3.2\n";exit} | ||
71 | "proc /proc proc" | ||
72 | } | ||
73 | expect { | ||
74 | timeout {puts "TESTING ERROR 3.3\n";exit} | ||
75 | "proc /proc/sys proc" | ||
76 | } | ||
77 | expect { | ||
78 | timeout {puts "TESTING ERROR 3.4\n";exit} | ||
79 | "proc /proc/sysrq-trigger proc" | ||
80 | } | ||
81 | expect { | ||
82 | timeout {puts "TESTING ERROR 3.5\n";exit} | ||
83 | "proc /proc/sys/kernel/hotplug" | ||
84 | } | ||
85 | expect { | ||
86 | timeout {puts "TESTING ERROR 3.6\n";exit} | ||
87 | "proc /proc/irq proc" | ||
88 | } | ||
89 | expect { | ||
90 | timeout {puts "TESTING ERROR 3.7\n";exit} | ||
91 | "proc /proc/bus proc" | ||
92 | } | ||
93 | after 100 | ||
94 | send -- "exit\r" | ||
95 | sleep 1 | ||
96 | |||
97 | # | ||
98 | # C | ||
99 | # | ||
100 | send -- "firejail --noprofile --chroot=/tmp/chroot\r" | ||
101 | expect { | ||
102 | timeout {puts "TESTING ERROR 4\n";exit} | ||
103 | "Child process initialized" | ||
104 | } | ||
105 | sleep 1 | ||
106 | |||
107 | send -- "cat /proc/mounts | grep proc\r" | ||
108 | expect { | ||
109 | timeout {puts "TESTING ERROR 5.1\n";exit} | ||
110 | "proc /proc proc" | ||
111 | } | ||
112 | expect { | ||
113 | timeout {puts "TESTING ERROR 5.2\n";exit} | ||
114 | "proc /proc proc" | ||
115 | } | ||
116 | expect { | ||
117 | timeout {puts "TESTING ERROR 5.3\n";exit} | ||
118 | "proc /proc/sys proc" | ||
119 | } | ||
120 | expect { | ||
121 | timeout {puts "TESTING ERROR 5.4\n";exit} | ||
122 | "proc /proc/sysrq-trigger proc" | ||
123 | } | ||
124 | expect { | ||
125 | timeout {puts "TESTING ERROR 5.5\n";exit} | ||
126 | "proc /proc/sys/kernel/hotplug" | ||
127 | } | ||
128 | expect { | ||
129 | timeout {puts "TESTING ERROR 5.6\n";exit} | ||
130 | "proc /proc/irq proc" | ||
131 | } | ||
132 | expect { | ||
133 | timeout {puts "TESTING ERROR 5.7\n";exit} | ||
134 | "proc /proc/bus proc" | ||
135 | } | ||
136 | after 100 | ||
137 | send -- "exit\r" | ||
138 | sleep 1 | ||
139 | |||
140 | |||
141 | puts "\nall done\n" | ||