aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorArnold D. Robbins <arnold@skeeve.com>2015-02-11 23:26:38 +0200
committerArnold D. Robbins <arnold@skeeve.com>2015-02-11 23:26:38 +0200
commit378e213c953d6482ae4d92a69b526cdeaef1f26f (patch)
treebc4c1b54d83e4869f9aae794aac6688f04cbbc76 /test
parent7f9f66525d7d82816eba352efdf58497373a47bf (diff)
parentf2c0bdf60b053c28d6cde7faf1b014e5b7f7deaf (diff)
downloadegawk-378e213c953d6482ae4d92a69b526cdeaef1f26f.tar.gz
egawk-378e213c953d6482ae4d92a69b526cdeaef1f26f.tar.bz2
egawk-378e213c953d6482ae4d92a69b526cdeaef1f26f.zip
Merge branch 'master' into non-fatal-io-2
Diffstat (limited to 'test')
-rw-r--r--test/ChangeLog5
-rw-r--r--test/Makefile.am10
-rw-r--r--test/Makefile.in10
-rw-r--r--test/profile0.awk1
-rw-r--r--test/profile0.in2
-rw-r--r--test/profile0.ok6
6 files changed, 32 insertions, 2 deletions
diff --git a/test/ChangeLog b/test/ChangeLog
index e888c669..d047ae0a 100644
--- a/test/ChangeLog
+++ b/test/ChangeLog
@@ -1,3 +1,8 @@
+2015-02-10 Arnold D. Robbins <arnold@skeeve.com>
+
+ * Makefile.am (profile0): New test.
+ * profile0.awk, profile0.in, profile0.ok: New files.
+
2015-02-08 Arnold D. Robbins <arnold@skeeve.com>
* nonfatal1.awk, nonfatal2.awk: String is now "NONFATAL".
diff --git a/test/Makefile.am b/test/Makefile.am
index 053f89fd..38b0d00b 100644
--- a/test/Makefile.am
+++ b/test/Makefile.am
@@ -714,6 +714,8 @@ EXTRA_DIST = \
prmreuse.ok \
procinfs.awk \
procinfs.ok \
+ profile0.awk \
+ profile0.ok \
profile2.ok \
profile3.awk \
profile3.ok \
@@ -1048,7 +1050,7 @@ GAWK_EXT_TESTS = \
nastyparm next nondec nondec2 \
nonfatal1 nonfatal2 \
patsplit posix printfbad1 printfbad2 printfbad3 printfbad4 printhuge procinfs \
- profile1 profile2 profile3 profile4 profile5 profile6 profile7 \
+ profile0 profile1 profile2 profile3 profile4 profile5 profile6 profile7 \
profile8 pty1 \
rebuf regnul1 regnul2 regx8bit reginttrad reint reint2 rsgetline rsglstdin rsstart1 \
rsstart2 rsstart3 rstest6 shadow sortfor sortu split_after_fpat \
@@ -1699,6 +1701,12 @@ dumpvars::
@grep -v ENVIRON < awkvars.out | grep -v PROCINFO > _$@; rm awkvars.out
@-$(CMP) "$(srcdir)"/$@.ok _$@ && rm -f _$@
+profile0:
+ @echo $@
+ @$(AWK) --profile=ap-$@.out -f "$(srcdir)"/$@.awk "$(srcdir)"/$@.in > /dev/null
+ @sed 1,2d < ap-$@.out > _$@; rm ap-$@.out
+ @-$(CMP) "$(srcdir)"/$@.ok _$@ && rm -f _$@
+
profile1:
@echo $@
@$(AWK) -f "$(srcdir)"/xref.awk "$(srcdir)"/dtdgport.awk > _$@.out1
diff --git a/test/Makefile.in b/test/Makefile.in
index 25ea167b..9b235e46 100644
--- a/test/Makefile.in
+++ b/test/Makefile.in
@@ -971,6 +971,8 @@ EXTRA_DIST = \
prmreuse.ok \
procinfs.awk \
procinfs.ok \
+ profile0.awk \
+ profile0.ok \
profile2.ok \
profile3.awk \
profile3.ok \
@@ -1304,7 +1306,7 @@ GAWK_EXT_TESTS = \
nastyparm next nondec nondec2 \
nonfatal1 nonfatal2 \
patsplit posix printfbad1 printfbad2 printfbad3 printfbad4 printhuge procinfs \
- profile1 profile2 profile3 profile4 profile5 profile6 profile7 \
+ profile0 profile1 profile2 profile3 profile4 profile5 profile6 profile7 \
profile8 pty1 \
rebuf regnul1 regnul2 regx8bit reginttrad reint reint2 rsgetline rsglstdin rsstart1 \
rsstart2 rsstart3 rstest6 shadow sortfor sortu split_after_fpat \
@@ -2137,6 +2139,12 @@ dumpvars::
@grep -v ENVIRON < awkvars.out | grep -v PROCINFO > _$@; rm awkvars.out
@-$(CMP) "$(srcdir)"/$@.ok _$@ && rm -f _$@
+profile0:
+ @echo $@
+ @$(AWK) --profile=ap-$@.out -f "$(srcdir)"/$@.awk "$(srcdir)"/$@.in > /dev/null
+ @sed 1,2d < ap-$@.out > _$@; rm ap-$@.out
+ @-$(CMP) "$(srcdir)"/$@.ok _$@ && rm -f _$@
+
profile1:
@echo $@
@$(AWK) -f "$(srcdir)"/xref.awk "$(srcdir)"/dtdgport.awk > _$@.out1
diff --git a/test/profile0.awk b/test/profile0.awk
new file mode 100644
index 00000000..a42e94df
--- /dev/null
+++ b/test/profile0.awk
@@ -0,0 +1 @@
+NR == 1
diff --git a/test/profile0.in b/test/profile0.in
new file mode 100644
index 00000000..7bba8c8e
--- /dev/null
+++ b/test/profile0.in
@@ -0,0 +1,2 @@
+line 1
+line 2
diff --git a/test/profile0.ok b/test/profile0.ok
new file mode 100644
index 00000000..2e3c5728
--- /dev/null
+++ b/test/profile0.ok
@@ -0,0 +1,6 @@
+ # Rule(s)
+
+ 2 NR == 1 { # 1
+ 1 print $0
+ }
+