diff options
author | netblue30 <netblue30@yahoo.com> | 2016-04-06 20:40:45 -0400 |
---|---|---|
committer | netblue30 <netblue30@yahoo.com> | 2016-04-06 20:40:45 -0400 |
commit | 7526e567cd80ceec483ce3546f6fe9897e6ffd48 (patch) | |
tree | 5de7f1534ec0574b59c831838dd6d75a33d2f996 /test | |
parent | ssh/scp/sftp fixes (diff) | |
download | firejail-7526e567cd80ceec483ce3546f6fe9897e6ffd48.tar.gz firejail-7526e567cd80ceec483ce3546f6fe9897e6ffd48.tar.zst firejail-7526e567cd80ceec483ce3546f6fe9897e6ffd48.zip |
--cpu.print
Diffstat (limited to 'test')
-rwxr-xr-x | test/cpu-print.exp | 21 | ||||
-rwxr-xr-x | test/test.sh | 4 |
2 files changed, 25 insertions, 0 deletions
diff --git a/test/cpu-print.exp b/test/cpu-print.exp new file mode 100755 index 000000000..d8e3fbb04 --- /dev/null +++ b/test/cpu-print.exp | |||
@@ -0,0 +1,21 @@ | |||
1 | #!/usr/bin/expect -f | ||
2 | |||
3 | set timeout 10 | ||
4 | spawn $env(SHELL) | ||
5 | match_max 100000 | ||
6 | |||
7 | send -- "firejail --name=test --cpu=1,2\r" | ||
8 | expect { | ||
9 | timeout {puts "TESTING ERROR 0\n";exit} | ||
10 | "Child process initialized" | ||
11 | } | ||
12 | sleep 2 | ||
13 | |||
14 | spawn $env(SHELL) | ||
15 | send -- "firejail --cpu.print=test\r" | ||
16 | expect { | ||
17 | timeout {puts "TESTING ERROR 1\n";exit} | ||
18 | "Cpus_allowed_list: 1-2" | ||
19 | } | ||
20 | sleep 1 | ||
21 | puts "\nall done\n" | ||
diff --git a/test/test.sh b/test/test.sh index ca2108bc5..96ef8f423 100755 --- a/test/test.sh +++ b/test/test.sh | |||
@@ -6,6 +6,10 @@ | |||
6 | 6 | ||
7 | ./fscheck.sh | 7 | ./fscheck.sh |
8 | 8 | ||
9 | echo "TESTING: cpu.print (cpu-print.exp)" | ||
10 | echo "TESTING: failing under VirtualBox where there is only one CPU" | ||
11 | ./cpu-print.exp | ||
12 | |||
9 | echo "TESTING: bandwidth (bandwidth.exp)" | 13 | echo "TESTING: bandwidth (bandwidth.exp)" |
10 | ./bandwidth.exp | 14 | ./bandwidth.exp |
11 | 15 | ||