aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorLibravatar netblue30 <netblue30@yahoo.com>2016-04-02 18:59:52 -0400
committerLibravatar netblue30 <netblue30@yahoo.com>2016-04-02 18:59:52 -0400
commitc89bd3131770903c7121c271a7763b2ef1912272 (patch)
treeb16afecd0a83554026d4a50355106fe12844b244 /test
parentMerge pull request #406 from avoidr/cmus.profile (diff)
downloadfirejail-c89bd3131770903c7121c271a7763b2ef1912272.tar.gz
firejail-c89bd3131770903c7121c271a7763b2ef1912272.tar.zst
firejail-c89bd3131770903c7121c271a7763b2ef1912272.zip
various fixes
Diffstat (limited to 'test')
-rwxr-xr-xtest/firefox-x11.exp14
-rwxr-xr-xtest/firefox.exp14
-rwxr-xr-xtest/test-profile.exp2
3 files changed, 27 insertions, 3 deletions
diff --git a/test/firefox-x11.exp b/test/firefox-x11.exp
index c82408896..8bc7fbd25 100755
--- a/test/firefox-x11.exp
+++ b/test/firefox-x11.exp
@@ -4,7 +4,7 @@ set timeout 10
4spawn $env(SHELL) 4spawn $env(SHELL)
5match_max 100000 5match_max 100000
6 6
7send -- "firejail --name=test --x11 --net=br0 firefox www.gentoo.org\r" 7send -- "firejail --name=test --x11 --net=br0 firefox -no-remote www.gentoo.org\r"
8sleep 10 8sleep 10
9 9
10spawn $env(SHELL) 10spawn $env(SHELL)
@@ -18,6 +18,10 @@ expect {
18 "firefox" {puts "firefox detected\n";} 18 "firefox" {puts "firefox detected\n";}
19 "iceweasel" {puts "iceweasel detected\n";} 19 "iceweasel" {puts "iceweasel detected\n";}
20} 20}
21expect {
22 timeout {puts "TESTING ERROR 3.2\n";exit}
23 "no-remote"
24}
21sleep 1 25sleep 1
22send -- "firejail --name=blablabla\r" 26send -- "firejail --name=blablabla\r"
23expect { 27expect {
@@ -34,6 +38,10 @@ expect {
34 " iceweasel" {puts "iceweasel detected\n";} 38 " iceweasel" {puts "iceweasel detected\n";}
35} 39}
36expect { 40expect {
41 timeout {puts "TESTING ERROR 5.0\n";exit}
42 "no-remote"
43}
44expect {
37 timeout {puts "TESTING ERROR 5.1 (seccomp)\n";exit} 45 timeout {puts "TESTING ERROR 5.1 (seccomp)\n";exit}
38 "Seccomp: 2" 46 "Seccomp: 2"
39} 47}
@@ -49,6 +57,10 @@ expect {
49 " iceweasel" {puts "iceweasel detected\n";} 57 " iceweasel" {puts "iceweasel detected\n";}
50} 58}
51expect { 59expect {
60 timeout {puts "TESTING ERROR 6.0\n";exit}
61 "no-remote"
62}
63expect {
52 timeout {puts "TESTING ERROR 6.1\n";exit} 64 timeout {puts "TESTING ERROR 6.1\n";exit}
53 "CapBnd:" 65 "CapBnd:"
54} 66}
diff --git a/test/firefox.exp b/test/firefox.exp
index c2e64e04f..d531cf977 100755
--- a/test/firefox.exp
+++ b/test/firefox.exp
@@ -4,7 +4,7 @@ set timeout 10
4spawn $env(SHELL) 4spawn $env(SHELL)
5match_max 100000 5match_max 100000
6 6
7send -- "firejail firefox www.gentoo.org\r" 7send -- "firejail firefox -no-remote www.gentoo.org\r"
8expect { 8expect {
9 timeout {puts "TESTING ERROR 0\n";exit} 9 timeout {puts "TESTING ERROR 0\n";exit}
10 "Reading profile /etc/firejail/firefox.profile" 10 "Reading profile /etc/firejail/firefox.profile"
@@ -26,6 +26,10 @@ expect {
26 "firefox" {puts "firefox detected\n";} 26 "firefox" {puts "firefox detected\n";}
27 "iceweasel" {puts "iceweasel detected\n";} 27 "iceweasel" {puts "iceweasel detected\n";}
28} 28}
29expect {
30 timeout {puts "TESTING ERROR 3.2\n";exit}
31 "no-remote"
32}
29sleep 1 33sleep 1
30send -- "firejail --name=blablabla\r" 34send -- "firejail --name=blablabla\r"
31expect { 35expect {
@@ -42,6 +46,10 @@ expect {
42 " iceweasel" {puts "iceweasel detected\n";} 46 " iceweasel" {puts "iceweasel detected\n";}
43} 47}
44expect { 48expect {
49 timeout {puts "TESTING ERROR 5.0\n";exit}
50 "no-remote"
51}
52expect {
45 timeout {puts "TESTING ERROR 5.1 (seccomp)\n";exit} 53 timeout {puts "TESTING ERROR 5.1 (seccomp)\n";exit}
46 "Seccomp: 2" 54 "Seccomp: 2"
47} 55}
@@ -57,6 +65,10 @@ expect {
57 " iceweasel" {puts "iceweasel detected\n";} 65 " iceweasel" {puts "iceweasel detected\n";}
58} 66}
59expect { 67expect {
68 timeout {puts "TESTING ERROR 6.0\n";exit}
69 "no-remote"
70}
71expect {
60 timeout {puts "TESTING ERROR 6.1\n";exit} 72 timeout {puts "TESTING ERROR 6.1\n";exit}
61 "CapBnd:" 73 "CapBnd:"
62} 74}
diff --git a/test/test-profile.exp b/test/test-profile.exp
index 89fe9c10a..a03e8db31 100755
--- a/test/test-profile.exp
+++ b/test/test-profile.exp
@@ -10,7 +10,7 @@ if { $argc != 1 } {
10 exit 10 exit
11} 11}
12 12
13send -- "firejail --profile=$argv\r" 13send -- "firejail --profile=$argv /bin/bash\r"
14expect { 14expect {
15 timeout {puts "TESTING ERROR 0\n";exit} 15 timeout {puts "TESTING ERROR 0\n";exit}
16 "Child process initialized" 16 "Child process initialized"