From 2da675a42183f2c9fa7f652f31799e1a41ed5ee4 Mon Sep 17 00:00:00 2001 From: netblue30 Date: Thu, 17 Dec 2015 12:09:42 -0500 Subject: testing --- test/name.profile | 1 + test/option-join-profile.exp | 39 +++++++++++++++++++++++++++++++++++++++ test/test.sh | 3 +++ 3 files changed, 43 insertions(+) create mode 100644 test/name.profile create mode 100755 test/option-join-profile.exp (limited to 'test') diff --git a/test/name.profile b/test/name.profile new file mode 100644 index 000000000..69e605600 --- /dev/null +++ b/test/name.profile @@ -0,0 +1 @@ +name svntesting diff --git a/test/option-join-profile.exp b/test/option-join-profile.exp new file mode 100755 index 000000000..d208a7f23 --- /dev/null +++ b/test/option-join-profile.exp @@ -0,0 +1,39 @@ +#!/usr/bin/expect -f + +set timeout 10 +spawn $env(SHELL) +match_max 100000 + +send -- "firejail --profile=name.profile\r" +expect { + timeout {puts "TESTING ERROR 0\n";exit} + "Child process initialized" +} +sleep 3 + +spawn $env(SHELL) +send -- "firejail --join=svntesting;pwd\r" +expect { + timeout {puts "TESTING ERROR 1\n";exit} + "Switching to pid" +} +sleep 1 + + +spawn $env(SHELL) +send -- "firejail --shutdown=svntesting;pwd\r" +expect { + timeout {puts "TESTING ERROR 3\n";exit} + "home" +} +sleep 1 + +send -- "firejail --list;pwd\r" +expect { + timeout {puts "TESTING ERROR 4\n";exit} + "svntesting" {puts "TESTING ERROR 5\n";exit} + "home" +} +sleep 1 + +puts "\nall done\n" diff --git a/test/test.sh b/test/test.sh index 86ae874d9..78fc7b974 100755 --- a/test/test.sh +++ b/test/test.sh @@ -95,6 +95,9 @@ echo "TESTING: shutdown" echo "TESTING: join" ./option-join.exp +echo "TESTING: join profile" +./option-join-profile.exp + echo "TESTING: firejail in firejail" ./firejail-in-firejail.exp -- cgit v1.2.3-54-g00ecf