aboutsummaryrefslogtreecommitdiffstats
path: root/test/network/bandwidth.exp
diff options
context:
space:
mode:
Diffstat (limited to 'test/network/bandwidth.exp')
-rwxr-xr-xtest/network/bandwidth.exp68
1 files changed, 0 insertions, 68 deletions
diff --git a/test/network/bandwidth.exp b/test/network/bandwidth.exp
deleted file mode 100755
index ef68165b7..000000000
--- a/test/network/bandwidth.exp
+++ /dev/null
@@ -1,68 +0,0 @@
1#!/usr/bin/expect -f
2# This file is part of Firejail project
3# Copyright (C) 2014-2023 Firejail Authors
4# License GPL v2
5
6set timeout 10
7spawn $env(SHELL)
8match_max 100000
9
10send -- "firejail --name=test --net=br0\r"
11expect {
12 timeout {puts "TESTING ERROR 0\n";exit}
13 -re "Child process initialized in \[0-9\]+.\[0-9\]+ ms"
14}
15sleep 1
16
17spawn $env(SHELL)
18send -- "firejail --bandwidth=test status\r"
19expect {
20 timeout {puts "TESTING ERROR 1\n";exit}
21 "qdisc * 0: dev eth0"
22}
23sleep 1
24
25send -- "firejail --bandwidth=test set br0 50 10\r"
26expect {
27 timeout {puts "TESTING ERROR 2\n";exit}
28 "Configuring interface eth0"
29}
30expect {
31 timeout {puts "TESTING ERROR 3\n";exit}
32 "configuring tc ingress"
33}
34expect {
35 timeout {puts "TESTING ERROR 4\n";exit}
36 "configuring tc egress"
37}
38
39send -- "firejail --bandwidth=test status\r"
40expect {
41 timeout {puts "TESTING ERROR 5\n";exit}
42 "dev eth0"
43}
44expect {
45 timeout {puts "TESTING ERROR 6\n";exit}
46 "rate 80Kbit burst 10Kb"
47}
48sleep 1
49
50send -- "firejail --bandwidth=test clear br0\r"
51expect {
52 timeout {puts "TESTING ERROR 7\n";exit}
53 "Removing bandwidth limits"
54}
55sleep 1
56
57send -- "stty -echo\r"
58after 100
59
60send -- "firejail --bandwidth=test status; echo done\r"
61expect {
62 timeout {puts "TESTING ERROR 8\n";exit}
63 "rate 80Kbit burst 10Kb" {puts "TESTING ERROR 9\n";exit}
64 "done"
65}
66after 100
67
68puts "\nall done\n"