summaryrefslogtreecommitdiffstats
path: root/bin/test
diff options
context:
space:
mode:
authorjmmv <jmmv@FreeBSD.org>2014-01-10 10:39:01 +0000
committerjmmv <jmmv@FreeBSD.org>2014-01-10 10:39:01 +0000
commitd2680a1ea6b481e1a47bc981a0818c5407f06fcf (patch)
treefb53e52579b547549223a537f6bda7411cbe878e /bin/test
parent6747585ab996227788d41b519534c2ab3ba90737 (diff)
downloadFreeBSD-src-d2680a1ea6b481e1a47bc981a0818c5407f06fcf.zip
FreeBSD-src-d2680a1ea6b481e1a47bc981a0818c5407f06fcf.tar.gz
Run the sh(1) and test(1) tests as unprivileged.
One of the tests for test(1) fails and some of the tests for sh(1) are silently bypassed when running as root. To fix these tests and ensure they all run, mark the test programs for sh(1) and test(1) as requiring an unprivileged user. (This should and will be the default in Kyua but isn't yet.) MFC after: 1 week
Diffstat (limited to 'bin/test')
-rw-r--r--bin/test/tests/Kyuafile12
-rw-r--r--bin/test/tests/Makefile1
2 files changed, 13 insertions, 0 deletions
diff --git a/bin/test/tests/Kyuafile b/bin/test/tests/Kyuafile
new file mode 100644
index 0000000..b2e4b32
--- /dev/null
+++ b/bin/test/tests/Kyuafile
@@ -0,0 +1,12 @@
+-- $FreeBSD$
+
+syntax(2)
+
+test_suite("FreeBSD")
+
+-- Some tests in here are silently not run when the tests are executed as
+-- root. Explicitly tell Kyua to drop privileges.
+--
+-- TODO(jmmv): Kyua needs to do this by default, not only when explicitly
+-- requested. See https://code.google.com/p/kyua/issues/detail?id=6
+tap_test_program{name="legacy_test", required_user="unprivileged"}
diff --git a/bin/test/tests/Makefile b/bin/test/tests/Makefile
index c5743de..dfffbed 100644
--- a/bin/test/tests/Makefile
+++ b/bin/test/tests/Makefile
@@ -3,6 +3,7 @@
.include <bsd.own.mk>
TESTSDIR= ${TESTSBASE}/bin/test
+KYUAFILE= yes
TAP_TESTS_SH= legacy_test
OpenPOWER on IntegriCloud