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