diff options
author | 2017-05-30 20:46:03 +0000 | |
---|---|---|
committer | 2017-05-30 20:46:03 +0000 | |
commit | c52384588f7cb85c5d9f106573091eef66991ed5 (patch) | |
tree | cb9686d20d71873f34dc65591f532f3b15163db4 | |
parent | event injection framework, will be used for other features coming shortly (diff) | |
download | wireguard-openbsd-c52384588f7cb85c5d9f106573091eef66991ed5.tar.xz wireguard-openbsd-c52384588f7cb85c5d9f106573091eef66991ed5.zip |
First pass to make bluhm@ happy regarding doas regress conf.
1. Make permit tests use wsrc instead of wobj (because basically, to run
test you need obj being writable, unless you want to pollute /usr/src);
2. Test if current user is in wobj group prior running the test, and skip
the test if he is not.
-rw-r--r-- | regress/usr.bin/doas/Makefile | 5 | ||||
-rw-r--r-- | regress/usr.bin/doas/t-permit-1.conf | 6 |
2 files changed, 6 insertions, 5 deletions
diff --git a/regress/usr.bin/doas/Makefile b/regress/usr.bin/doas/Makefile index 0f717f18778..9a0e854546b 100644 --- a/regress/usr.bin/doas/Makefile +++ b/regress/usr.bin/doas/Makefile @@ -1,4 +1,4 @@ -# $OpenBSD: Makefile,v 1.3 2015/07/28 12:25:27 zhuk Exp $ +# $OpenBSD: Makefile,v 1.4 2017/05/30 20:46:03 zhuk Exp $ REGRESS_TARGETS = \ t-okay \ @@ -41,7 +41,8 @@ ${t}: .for t in ${REGRESS_TARGETS:M*-permit*} ${t}: @echo '$@' - @rv=true; \ + @id | grep '(wobj)' >/dev/null || { echo SKIPPED; exit 0; } ; \ + rv=true; \ while read ident cmdline; do \ read expected; \ set +e; \ diff --git a/regress/usr.bin/doas/t-permit-1.conf b/regress/usr.bin/doas/t-permit-1.conf index 6a51afbe4f9..ed0e1082097 100644 --- a/regress/usr.bin/doas/t-permit-1.conf +++ b/regress/usr.bin/doas/t-permit-1.conf @@ -1,3 +1,3 @@ -permit :wsrc as root cmd echo args la-la-la -permit :wsrc as operator cmd echo args -permit nopass :wsrc as www cmd echo args slackers +permit :wobj as root cmd echo args la-la-la +permit :wobj as operator cmd echo args +permit nopass :wobj as www cmd echo args slackers |