summaryrefslogtreecommitdiffstats
path: root/gnu/usr.bin/grep/tests/spencer1.awk
diff options
context:
space:
mode:
authorobrien <obrien@FreeBSD.org>1999-11-22 09:32:57 +0000
committerobrien <obrien@FreeBSD.org>1999-11-22 09:32:57 +0000
commit18bbf176c89ad4e8bcded49759ff6f701c27ae3c (patch)
tree59edc7e5ea79e3ae16db7d18aad05ca222e21d23 /gnu/usr.bin/grep/tests/spencer1.awk
parentfac3cf264f5ad722ebdc3390aa6a6497b6b000e5 (diff)
downloadFreeBSD-src-18bbf176c89ad4e8bcded49759ff6f701c27ae3c.zip
FreeBSD-src-18bbf176c89ad4e8bcded49759ff6f701c27ae3c.tar.gz
Virgin import of GNU Grep 2.3 [trimmed down].
Diffstat (limited to 'gnu/usr.bin/grep/tests/spencer1.awk')
-rw-r--r--gnu/usr.bin/grep/tests/spencer1.awk14
1 files changed, 14 insertions, 0 deletions
diff --git a/gnu/usr.bin/grep/tests/spencer1.awk b/gnu/usr.bin/grep/tests/spencer1.awk
new file mode 100644
index 0000000..b66b8f5
--- /dev/null
+++ b/gnu/usr.bin/grep/tests/spencer1.awk
@@ -0,0 +1,14 @@
+BEGIN {
+ FS = "@";
+ printf ("failures=0\n");
+}
+
+$0 !~ /^#/ && NF = 3 {
+ printf ("echo '%s'|${GREP} -E -e '%s' > /dev/null 2>&1\n",$3, $2);
+ printf ("if test $? -ne %s ; then\n", $1);
+ printf ("\techo Spencer test \\#%d failed\n", ++n);
+ printf ("\tfailures=1\n");
+ printf ("fi\n");
+}
+
+END { printf ("exit $failures\n"); }
OpenPOWER on IntegriCloud