diff options
Diffstat (limited to 'test/sysutils')
-rwxr-xr-x | test/sysutils/sysutils.sh | 8 | ||||
-rwxr-xr-x | test/sysutils/whois.exp | 17 |
2 files changed, 25 insertions, 0 deletions
diff --git a/test/sysutils/sysutils.sh b/test/sysutils/sysutils.sh index bab243c4b..a1aaa80a7 100755 --- a/test/sysutils/sysutils.sh +++ b/test/sysutils/sysutils.sh | |||
@@ -127,3 +127,11 @@ else | |||
127 | echo "TESTING SKIP: strings not found" | 127 | echo "TESTING SKIP: strings not found" |
128 | fi | 128 | fi |
129 | 129 | ||
130 | if command -v whois | ||
131 | then | ||
132 | echo "TESTING: whois" | ||
133 | ./whois.exp | ||
134 | else | ||
135 | echo "TESTING SKIP: whois not found" | ||
136 | fi | ||
137 | |||
diff --git a/test/sysutils/whois.exp b/test/sysutils/whois.exp new file mode 100755 index 000000000..29190253c --- /dev/null +++ b/test/sysutils/whois.exp | |||
@@ -0,0 +1,17 @@ | |||
1 | #!/usr/bin/expect -f | ||
2 | # This file is part of Firejail project | ||
3 | # Copyright (C) 2014-2022 Firejail Authors | ||
4 | # License GPL v2 | ||
5 | |||
6 | set timeout 10 | ||
7 | spawn $env(SHELL) | ||
8 | match_max 100000 | ||
9 | |||
10 | send -- "firejail whois debian.org\r" | ||
11 | expect { | ||
12 | timeout {puts "TESTING ERROR 0\n";exit} | ||
13 | "Domain Name" | ||
14 | } | ||
15 | |||
16 | after 100 | ||
17 | puts "\nall done\n" | ||