diff options
author | Reiner Herrmann <reiner@reiner-h.de> | 2018-08-16 18:36:36 +0200 |
---|---|---|
committer | Reiner Herrmann <reiner@reiner-h.de> | 2018-08-16 18:39:08 +0200 |
commit | c3edb7511a20970894fad81e647a8dabe5e5bac9 (patch) | |
tree | ffc77c732ca97817ae0536e6aeff41769c11a254 /test | |
parent | Unlink files at end (diff) | |
download | firejail-c3edb7511a20970894fad81e647a8dabe5e5bac9.tar.gz firejail-c3edb7511a20970894fad81e647a8dabe5e5bac9.tar.zst firejail-c3edb7511a20970894fad81e647a8dabe5e5bac9.zip |
tests: make top output independent of username, which could be too long
Diffstat (limited to 'test')
-rwxr-xr-x | test/environment/nice.exp | 30 |
1 files changed, 3 insertions, 27 deletions
diff --git a/test/environment/nice.exp b/test/environment/nice.exp index b989ea37a..9a7e2e9f7 100755 --- a/test/environment/nice.exp +++ b/test/environment/nice.exp | |||
@@ -14,11 +14,7 @@ expect { | |||
14 | } | 14 | } |
15 | sleep 1 | 15 | sleep 1 |
16 | 16 | ||
17 | send -- "top -b -n 1\r" | 17 | send -- "top -b -n 1 | awk '{ print \$4, \$12 }'\r" |
18 | expect { | ||
19 | timeout {puts "TESTING ERROR 1\n";exit} | ||
20 | $env(USER) | ||
21 | } | ||
22 | expect { | 18 | expect { |
23 | timeout {puts "TESTING ERROR 2\n";exit} | 19 | timeout {puts "TESTING ERROR 2\n";exit} |
24 | "15" | 20 | "15" |
@@ -28,10 +24,6 @@ expect { | |||
28 | "bash" | 24 | "bash" |
29 | } | 25 | } |
30 | expect { | 26 | expect { |
31 | timeout {puts "TESTING ERROR 4\n";exit} | ||
32 | $env(USER) | ||
33 | } | ||
34 | expect { | ||
35 | timeout {puts "TESTING ERROR 5\n";exit} | 27 | timeout {puts "TESTING ERROR 5\n";exit} |
36 | "15" | 28 | "15" |
37 | } | 29 | } |
@@ -51,11 +43,7 @@ expect { | |||
51 | } | 43 | } |
52 | sleep 1 | 44 | sleep 1 |
53 | 45 | ||
54 | send -- "top -b -n 1\r" | 46 | send -- "top -b -n 1 | awk '{ print \$4, \$12 }'\r" |
55 | expect { | ||
56 | timeout {puts "TESTING ERROR 11\n";exit} | ||
57 | $env(USER) | ||
58 | } | ||
59 | expect { | 47 | expect { |
60 | timeout {puts "TESTING ERROR 12\n";exit} | 48 | timeout {puts "TESTING ERROR 12\n";exit} |
61 | "15" | 49 | "15" |
@@ -65,10 +53,6 @@ expect { | |||
65 | "bash" | 53 | "bash" |
66 | } | 54 | } |
67 | expect { | 55 | expect { |
68 | timeout {puts "TESTING ERROR 14\n";exit} | ||
69 | $env(USER) | ||
70 | } | ||
71 | expect { | ||
72 | timeout {puts "TESTING ERROR 15\n";exit} | 56 | timeout {puts "TESTING ERROR 15\n";exit} |
73 | "15" | 57 | "15" |
74 | } | 58 | } |
@@ -90,11 +74,7 @@ expect { | |||
90 | } | 74 | } |
91 | sleep 1 | 75 | sleep 1 |
92 | 76 | ||
93 | send -- "top -b -n 1\r" | 77 | send -- "top -b -n 1 | awk '{ print \$4, \$12 }'\r" |
94 | expect { | ||
95 | timeout {puts "TESTING ERROR 18\n";exit} | ||
96 | $env(USER) | ||
97 | } | ||
98 | expect { | 78 | expect { |
99 | timeout {puts "TESTING ERROR 19\n";exit} | 79 | timeout {puts "TESTING ERROR 19\n";exit} |
100 | "0" | 80 | "0" |
@@ -104,10 +84,6 @@ expect { | |||
104 | "bash" | 84 | "bash" |
105 | } | 85 | } |
106 | expect { | 86 | expect { |
107 | timeout {puts "TESTING ERROR 21\n";exit} | ||
108 | $env(USER) | ||
109 | } | ||
110 | expect { | ||
111 | timeout {puts "TESTING ERROR 22\n";exit} | 87 | timeout {puts "TESTING ERROR 22\n";exit} |
112 | "0" | 88 | "0" |
113 | } | 89 | } |