aboutsummaryrefslogtreecommitdiffstats
path: root/test/root/option_tmpfs.exp
diff options
context:
space:
mode:
authorLibravatar netblue30 <netblue30@yahoo.com>2016-09-15 09:59:11 -0400
committerLibravatar netblue30 <netblue30@yahoo.com>2016-09-15 09:59:11 -0400
commitfc116c063938d5e141d5fbc38e8013d9832ef315 (patch)
tree382b401cc0a9efeda1509a88bd430cd68b741346 /test/root/option_tmpfs.exp
parentfixed /etc/login.def reading on Mageia systems (diff)
downloadfirejail-fc116c063938d5e141d5fbc38e8013d9832ef315.tar.gz
firejail-fc116c063938d5e141d5fbc38e8013d9832ef315.tar.zst
firejail-fc116c063938d5e141d5fbc38e8013d9832ef315.zip
testing
Diffstat (limited to 'test/root/option_tmpfs.exp')
-rwxr-xr-xtest/root/option_tmpfs.exp44
1 files changed, 44 insertions, 0 deletions
diff --git a/test/root/option_tmpfs.exp b/test/root/option_tmpfs.exp
new file mode 100755
index 000000000..20e42a858
--- /dev/null
+++ b/test/root/option_tmpfs.exp
@@ -0,0 +1,44 @@
1#!/usr/bin/expect -f
2
3set timeout 10
4spawn $env(SHELL)
5match_max 100000
6
7send -- "firejail --tmpfs=/var\r"
8expect {
9 timeout {puts "TESTING ERROR 0\n";exit}
10 "Child process initialized"
11}
12sleep 1
13
14send -- "ls -l /var;pwd\r"
15expect {
16 timeout {puts "TESTING ERROR 1\n";exit}
17 "total 0"
18}
19expect {
20 timeout {puts "TESTING ERROR 2\n";exit}
21 "/root"
22}
23sleep 1
24send -- "exit\r"
25sleep 2
26
27send -- "firejail --debug-check-filename --tmpfs=\"bla&&bla\"\r"
28expect {
29 timeout {puts "TESTING ERROR 13.1\n";exit}
30 "Checking filename bla&&bla"
31}
32expect {
33 timeout {puts "TESTING ERROR 13.2\n";exit}
34 "Error:"
35}
36expect {
37 timeout {puts "TESTING ERROR 13.3\n";exit}
38 "is an invalid filename"
39}
40after 100
41
42
43puts "\nall done\n"
44