]> granicus.if.org Git - sudo/commitdiff
convert test2 to use testsudoers
authorTodd C. Miller <Todd.Miller@courtesan.com>
Wed, 23 Feb 2011 20:26:13 +0000 (15:26 -0500)
committerTodd C. Miller <Todd.Miller@courtesan.com>
Wed, 23 Feb 2011 20:26:13 +0000 (15:26 -0500)
plugins/sudoers/regress/testsudoers/test2.out [new file with mode: 0644]
plugins/sudoers/regress/testsudoers/test2.sh [moved from plugins/sudoers/regress/visudo/test2.sh with 70% similarity]
plugins/sudoers/regress/visudo/test2.out [deleted file]

diff --git a/plugins/sudoers/regress/testsudoers/test2.out b/plugins/sudoers/regress/testsudoers/test2.out
new file mode 100644 (file)
index 0000000..ad7fc39
--- /dev/null
@@ -0,0 +1,9 @@
+Parses OK.
+
+
+
+%:C/non UNIX 0 c       ALL = (ALL) ALL
+%:C/non\'UNIX\'1 c     ALL = (ALL) ALL
+%:C/non"UNIX"0 c       ALL = (ALL) ALL
+%:C/non_UNIX_0 c       ALL = (ALL) ALL
+%:C/non\'UNIX_3 c      ALL = (ALL) ALL
similarity index 70%
rename from plugins/sudoers/regress/visudo/test2.sh
rename to plugins/sudoers/regress/testsudoers/test2.sh
index 6014a0de6a83120fd6ba6e9cfb67daf2c0922c72..83cc00dd49f3c59e258800f2c072b65b46497af0 100755 (executable)
@@ -4,9 +4,9 @@
 # See http://www.sudo.ws/bugs/show_bug.cgi?id=437
 #
 
-WANT=${SRCDIR-.}/regress/visudo/test1.ok
-GOT=vs_test1.out
-./visudo -c -f- > $GOT <<EOF
+WANT=${SRCDIR-.}/regress/testsudoers/test2.out
+GOT=ts_test2.out
+./testsudoers -d > $GOT <<EOF
 "%:C/non UNIX 0 c" ALL=(ALL) ALL
 "%:C/non\'UNIX\'1 c" ALL=(ALL) ALL
 "%:C/non\"UNIX\"0 c" ALL=(ALL) ALL
@@ -16,8 +16,8 @@ EOF
 
 # Check results
 if cmp $WANT $GOT >/dev/null; then
-    echo "visudo 2: OK"
+    echo "testsudoers 2: OK"
 else
-    echo "visudo 2: FAILED"
+    echo "testsudoers 2: FAILED"
     diff $WANT $GOT
 fi
diff --git a/plugins/sudoers/regress/visudo/test2.out b/plugins/sudoers/regress/visudo/test2.out
deleted file mode 100644 (file)
index e69de29..0000000