aboutsummaryrefslogtreecommitdiffstats
path: root/test/net_arp.exp
diff options
context:
space:
mode:
authorLibravatar netblue30 <netblue30@yahoo.com>2015-08-08 19:12:30 -0400
committerLibravatar netblue30 <netblue30@yahoo.com>2015-08-08 19:12:30 -0400
commit1379851360349d6617ad32944a25ee5e2bb74fc2 (patch)
treef69b48e90708bfa3c2723d5a27ed3e024c827b43 /test/net_arp.exp
parentdelete files (diff)
downloadfirejail-1379851360349d6617ad32944a25ee5e2bb74fc2.tar.gz
firejail-1379851360349d6617ad32944a25ee5e2bb74fc2.tar.zst
firejail-1379851360349d6617ad32944a25ee5e2bb74fc2.zip
Baseline firejail 0.9.28
Diffstat (limited to 'test/net_arp.exp')
-rwxr-xr-xtest/net_arp.exp71
1 files changed, 71 insertions, 0 deletions
diff --git a/test/net_arp.exp b/test/net_arp.exp
new file mode 100755
index 000000000..9e07744f3
--- /dev/null
+++ b/test/net_arp.exp
@@ -0,0 +1,71 @@
1#!/usr/bin/expect -f
2
3set timeout 10
4spawn $env(SHELL)
5match_max 100000
6
7send -- "firejail --net=br0 sleep 20 &\r"
8expect {
9 timeout {puts "TESTING ERROR 0\n";exit}
10 "Child process initialized"
11}
12send -- "firejail --net=br0 sleep 20 &\r"
13expect {
14 timeout {puts "TESTING ERROR 1\n";exit}
15 "Child process initialized"
16}
17send -- "firejail --net=br0 sleep 20 &\r"
18expect {
19 timeout {puts "TESTING ERROR 2\n";exit}
20 "Child process initialized"
21}
22send -- "firejail --net=br0 sleep 20 &\r"
23expect {
24 timeout {puts "TESTING ERROR 3\n";exit}
25 "Child process initialized"
26}
27send -- "firejail --net=br0 sleep 20 &\r"
28expect {
29 timeout {puts "TESTING ERROR 4\n";exit}
30 "Child process initialized"
31}
32
33# will fail
34send -- "firejail --net=br0 sleep 20 &\r"
35expect {
36 timeout {puts "TESTING ERROR 5n";exit}
37 "cannot assign an IP address"
38}
39
40send -- "firejail --net=br0 sleep 20 &\r"
41expect {
42 timeout {puts "TESTING ERROR 6\n";exit}
43 "cannot assign an IP address"
44}
45
46# check firejail --list
47send -- "firejail --list\r"
48expect {
49 timeout {puts "TESTING ERROR 7.1\n";exit}
50 "sleep 20"
51}
52expect {
53 timeout {puts "TESTING ERROR 7.2\n";exit}
54 "sleep 20"
55}
56expect {
57 timeout {puts "TESTING ERROR 7.3\n";exit}
58 "sleep 20"
59}
60expect {
61 timeout {puts "TESTING ERROR 7.4\n";exit}
62 "sleep 20"
63}
64expect {
65 timeout {puts "TESTING ERROR 7.5\n";exit}
66 "sleep 20"
67}
68
69# wait for snadboxes to be shutdown
70sleep 30
71puts "\n"