aboutsummaryrefslogtreecommitdiffstats
path: root/test/utils/build.exp
diff options
context:
space:
mode:
Diffstat (limited to 'test/utils/build.exp')
-rwxr-xr-xtest/utils/build.exp58
1 files changed, 58 insertions, 0 deletions
diff --git a/test/utils/build.exp b/test/utils/build.exp
new file mode 100755
index 000000000..de2a9b6ae
--- /dev/null
+++ b/test/utils/build.exp
@@ -0,0 +1,58 @@
1#!/usr/bin/expect -f
2# This file is part of Firejail project
3# Copyright (C) 2014-2018 Firejail Authors
4# License GPL v2
5
6set timeout 10
7spawn $env(SHELL)
8match_max 100000
9
10send -- "firejail --build cat ~/firejail-test-file-7699\r"
11expect {
12 timeout {puts "TESTING ERROR 0\n";exit}
13 "whitelist ~/firejail-test-file-7699"
14}
15expect {
16 timeout {puts "TESTING ERROR 0.1\n";exit}
17 "include /etc/firejail/whitelist-common.inc"
18}
19expect {
20 timeout {puts "TESTING ERROR 1\n";exit}
21 "private-tmp"
22}
23expect {
24 timeout {puts "TESTING ERROR 2\n";exit}
25 "private-dev"
26}
27expect {
28 timeout {puts "TESTING ERROR 3\n";exit}
29 "blacklist /var"
30}
31expect {
32 timeout {puts "TESTING ERROR 4\n";exit}
33 "private-bin cat,"
34}
35expect {
36 timeout {puts "TESTING ERROR 5\n";exit}
37 "caps.drop all"
38}
39expect {
40 timeout {puts "TESTING ERROR 6\n";exit}
41 "nonewprivs"
42}
43expect {
44 timeout {puts "TESTING ERROR 7\n";exit}
45 "seccomp"
46}
47expect {
48 timeout {puts "TESTING ERROR 8\n";exit}
49 "net none"
50}
51expect {
52 timeout {puts "TESTING ERROR 9\n";exit}
53 "shell none"
54}
55after 100
56
57
58puts "all done\n"