aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorLibravatar netblue30 <netblue30@yahoo.com>2016-04-21 14:37:53 -0400
committerLibravatar netblue30 <netblue30@yahoo.com>2016-04-21 14:37:53 -0400
commitad2f7bc496e3cc83bca2381515312dd2ef6fc7f1 (patch)
tree0a923afb486b1f13ab35d26138cdbf51e0961aec
parent--read-write option (diff)
downloadfirejail-ad2f7bc496e3cc83bca2381515312dd2ef6fc7f1.tar.gz
firejail-ad2f7bc496e3cc83bca2381515312dd2ef6fc7f1.tar.zst
firejail-ad2f7bc496e3cc83bca2381515312dd2ef6fc7f1.zip
make test-profiles
-rw-r--r--Makefile.in5
-rwxr-xr-xtest/profiles/profile_syntax.exp (renamed from test/profile_syntax.exp)3
-rwxr-xr-xtest/profiles/profile_syntax2.exp (renamed from test/profile_syntax2.exp)3
-rwxr-xr-xtest/profiles/profiles.sh19
-rwxr-xr-xtest/profiles/test-profile.exp (renamed from test/test-profile.exp)3
-rw-r--r--test/profiles/test.profile (renamed from test/test.profile)0
-rw-r--r--test/profiles/test2.profile (renamed from test/test2.profile)0
-rwxr-xr-xtest/test-profiles.sh10
-rwxr-xr-xtest/test.sh8
9 files changed, 33 insertions, 18 deletions
diff --git a/Makefile.in b/Makefile.in
index dfeea565b..8bf9d68a9 100644
--- a/Makefile.in
+++ b/Makefile.in
@@ -239,6 +239,7 @@ dist:
239 cd $(NAME)-$(VERSION); cp -a ../src .; cp -a ../etc .; cp -a ../platform .; rm -fr src/tools; cd .. 239 cd $(NAME)-$(VERSION); cp -a ../src .; cp -a ../etc .; cp -a ../platform .; rm -fr src/tools; cd ..
240 cd $(NAME)-$(VERSION); cp -a ../configure .; cp -a ../configure.ac .; cp -a ../Makefile.in .; cp -a ../install.sh .; cp -a ../mkman.sh .; cp -a ../mketc.sh .; cp -a ../mkdeb.sh .;cd .. 240 cd $(NAME)-$(VERSION); cp -a ../configure .; cp -a ../configure.ac .; cp -a ../Makefile.in .; cp -a ../install.sh .; cp -a ../mkman.sh .; cp -a ../mketc.sh .; cp -a ../mkdeb.sh .;cd ..
241 cd $(NAME)-$(VERSION); cp -a ../COPYING .; cp -a ../README .; cp -a ../RELNOTES .; cd .. 241 cd $(NAME)-$(VERSION); cp -a ../COPYING .; cp -a ../README .; cp -a ../RELNOTES .; cd ..
242 cd $(NAME)-$(VERSION); mkdir -p test; cp -a ../test/profiles test/.; cd ..
242 cd $(NAME)-$(VERSION); rm -fr `find . -name .svn`; rm -fr $(NAME)-$(VERSION); cd .. 243 cd $(NAME)-$(VERSION); rm -fr `find . -name .svn`; rm -fr $(NAME)-$(VERSION); cd ..
243 tar -cjvf $(NAME)-$(VERSION).tar.bz2 $(NAME)-$(VERSION) 244 tar -cjvf $(NAME)-$(VERSION).tar.bz2 $(NAME)-$(VERSION)
244 rm -fr $(NAME)-$(VERSION) 245 rm -fr $(NAME)-$(VERSION)
@@ -258,5 +259,9 @@ cppcheck: clean
258 259
259scan-build: clean 260scan-build: clean
260 scan-build make 261 scan-build make
262
261asc:; ./mkasc.sh $(VERSION) 263asc:; ./mkasc.sh $(VERSION)
262 264
265test-profiles:
266 cd test/profiles; ./profiles.sh | grep TESTING
267
diff --git a/test/profile_syntax.exp b/test/profiles/profile_syntax.exp
index 559947276..ecad1043b 100755
--- a/test/profile_syntax.exp
+++ b/test/profiles/profile_syntax.exp
@@ -1,4 +1,7 @@
1#!/usr/bin/expect -f 1#!/usr/bin/expect -f
2# This file is part of Firejail project
3# Copyright (C) 2014-2016 Firejail Authors
4# License GPL v2
2 5
3set timeout 10 6set timeout 10
4spawn $env(SHELL) 7spawn $env(SHELL)
diff --git a/test/profile_syntax2.exp b/test/profiles/profile_syntax2.exp
index 96e85ba93..ba83731be 100755
--- a/test/profile_syntax2.exp
+++ b/test/profiles/profile_syntax2.exp
@@ -1,4 +1,7 @@
1#!/usr/bin/expect -f 1#!/usr/bin/expect -f
2# This file is part of Firejail project
3# Copyright (C) 2014-2016 Firejail Authors
4# License GPL v2
2 5
3set timeout 10 6set timeout 10
4spawn $env(SHELL) 7spawn $env(SHELL)
diff --git a/test/profiles/profiles.sh b/test/profiles/profiles.sh
new file mode 100755
index 000000000..ea1f51c1a
--- /dev/null
+++ b/test/profiles/profiles.sh
@@ -0,0 +1,19 @@
1#!/bin/bash
2# This file is part of Firejail project
3# Copyright (C) 2014-2016 Firejail Authors
4# License GPL v2
5
6echo "TESTING: default profiles installed in /etc"
7PROFILES=`ls /etc/firejail/*.profile`
8for PROFILE in $PROFILES
9do
10 echo "TESTING: $PROFILE"
11 ./test-profile.exp $PROFILE
12done
13
14echo "TESTING: profile syntax (profiles/profile_syntax.exp)"
15./profile_syntax.exp
16
17echo "TESTING: profile syntax 2 (profiles/profile_syntax2.exp)"
18./profile_syntax2.exp
19
diff --git a/test/test-profile.exp b/test/profiles/test-profile.exp
index a03e8db31..590b42652 100755
--- a/test/test-profile.exp
+++ b/test/profiles/test-profile.exp
@@ -1,4 +1,7 @@
1#!/usr/bin/expect -f 1#!/usr/bin/expect -f
2# This file is part of Firejail project
3# Copyright (C) 2014-2016 Firejail Authors
4# License GPL v2
2 5
3set timeout 10 6set timeout 10
4spawn $env(SHELL) 7spawn $env(SHELL)
diff --git a/test/test.profile b/test/profiles/test.profile
index 1d69cc960..1d69cc960 100644
--- a/test/test.profile
+++ b/test/profiles/test.profile
diff --git a/test/test2.profile b/test/profiles/test2.profile
index d7e1a1f21..d7e1a1f21 100644
--- a/test/test2.profile
+++ b/test/profiles/test2.profile
diff --git a/test/test-profiles.sh b/test/test-profiles.sh
deleted file mode 100755
index d9142885b..000000000
--- a/test/test-profiles.sh
+++ /dev/null
@@ -1,10 +0,0 @@
1#!/bin/bash
2
3echo "TESTING: default profiles installed in /etc"
4PROFILES=`ls /etc/firejail/*.profile`
5for PROFILE in $PROFILES
6do
7 echo "TESTING: $PROFILE"
8 ./test-profile.exp $PROFILE
9done
10
diff --git a/test/test.sh b/test/test.sh
index 961b48807..0fa26d86d 100755
--- a/test/test.sh
+++ b/test/test.sh
@@ -2,8 +2,6 @@
2 2
3./chk_config.exp 3./chk_config.exp
4 4
5./test-profiles.sh
6
7./fscheck.sh 5./fscheck.sh
8 6
9echo "TESTING: cpu.print (cpu-print.exp)" 7echo "TESTING: cpu.print (cpu-print.exp)"
@@ -220,12 +218,6 @@ echo "TESTING: output (output.exp)"
220echo "TESTING: profile no permissions (profile_noperm.exp)" 218echo "TESTING: profile no permissions (profile_noperm.exp)"
221./profile_noperm.exp 219./profile_noperm.exp
222 220
223echo "TESTING: profile syntax (profile_syntax.exp)"
224./profile_syntax.exp
225
226echo "TESTING: profile syntax 2 (profile_syntax2.exp)"
227./profile_syntax2.exp
228
229echo "TESTING: profile rlimit (profile_rlimit.exp)" 221echo "TESTING: profile rlimit (profile_rlimit.exp)"
230./profile_rlimit.exp 222./profile_rlimit.exp
231 223