aboutsummaryrefslogtreecommitdiffstats
path: root/test/sysutils
diff options
context:
space:
mode:
authorLibravatar netblue30 <netblue30@yahoo.com>2017-11-15 08:10:04 -0500
committerLibravatar netblue30 <netblue30@yahoo.com>2017-11-15 08:10:04 -0500
commitc14c5050c1ab7eb01223e481166c7456c84adae8 (patch)
treec9294961784bb38788c38fd219d0aeeeebf5cf3d /test/sysutils
parentbsdtar profile, #1642 (diff)
downloadfirejail-c14c5050c1ab7eb01223e481166c7456c84adae8.tar.gz
firejail-c14c5050c1ab7eb01223e481166c7456c84adae8.tar.zst
firejail-c14c5050c1ab7eb01223e481166c7456c84adae8.zip
testing
Diffstat (limited to 'test/sysutils')
-rwxr-xr-xtest/sysutils/ping.exp16
-rwxr-xr-xtest/sysutils/sysutils.sh9
2 files changed, 25 insertions, 0 deletions
diff --git a/test/sysutils/ping.exp b/test/sysutils/ping.exp
new file mode 100755
index 000000000..a47f4d0e4
--- /dev/null
+++ b/test/sysutils/ping.exp
@@ -0,0 +1,16 @@
1#!/usr/bin/expect -f
2# This file is part of Firejail project
3# Copyright (C) 2014-2017 Firejail Authors
4# License GPL v2
5
6set timeout 10
7spawn $env(SHELL)
8match_max 100000
9
10send -- "firejail ping -c 3 yahoo.com\r"
11expect {
12 timeout {puts "TESTING ERROR 1\n";exit}
13 "3 packets transmitted, 3 received"
14}
15after 100
16puts "\nall done\n"
diff --git a/test/sysutils/sysutils.sh b/test/sysutils/sysutils.sh
index 859d782c6..8ec115d95 100755
--- a/test/sysutils/sysutils.sh
+++ b/test/sysutils/sysutils.sh
@@ -77,3 +77,12 @@ then
77else 77else
78 echo "TESTING SKIP: tar not found" 78 echo "TESTING SKIP: tar not found"
79fi 79fi
80
81which ping
82if [ "$?" -eq 0 ];
83then
84 echo "TESTING: ping"
85 ./ping.exp
86else
87 echo "TESTING SKIP: ping not found"
88fi