aboutsummaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorArnold D. Robbins <arnold@skeeve.com>2015-06-29 20:36:50 +0300
committerArnold D. Robbins <arnold@skeeve.com>2015-06-29 20:36:50 +0300
commit5cb179dbcfe1503b2eaffa87b5f7502f41482be2 (patch)
tree917ebd36146fb87b8ecb39fb1cca9f6b4e7e02ff /test
parent2befea585a321d9d092bfb99cbfa65350a839752 (diff)
downloadegawk-5cb179dbcfe1503b2eaffa87b5f7502f41482be2.tar.gz
egawk-5cb179dbcfe1503b2eaffa87b5f7502f41482be2.tar.bz2
egawk-5cb179dbcfe1503b2eaffa87b5f7502f41482be2.zip
Debugger fix, eval for builtin extensions + test.
Diffstat (limited to 'test')
-rw-r--r--test/ChangeLog6
-rw-r--r--test/Makefile.am10
-rw-r--r--test/Makefile.in10
-rw-r--r--test/dbugeval2.awk4
-rw-r--r--test/dbugeval2.in3
-rw-r--r--test/dbugeval2.ok7
6 files changed, 38 insertions, 2 deletions
diff --git a/test/ChangeLog b/test/ChangeLog
index f29dea72..c9a8e301 100644
--- a/test/ChangeLog
+++ b/test/ChangeLog
@@ -1,3 +1,9 @@
+2015-06-29 Arnold D. Robbins <arnold@skeeve.com>
+
+ * Makefile.am (dbugeval2): New test.
+ * dbugeval2.awk, dbugeval2.in, dbugeval2.ok: New files.
+ Thanks to Hermann Peifer for the report.
+
2015-06-28 Arnold D. Robbins <arnold@skeeve.com>
* Makefile.am (typedregex2): New test.
diff --git a/test/Makefile.am b/test/Makefile.am
index df1f1e2c..f646bc09 100644
--- a/test/Makefile.am
+++ b/test/Makefile.am
@@ -177,6 +177,9 @@ EXTRA_DIST = \
datanonl.ok \
dbugeval.in \
dbugeval.ok \
+ dbugeval2.awk \
+ dbugeval2.in \
+ dbugeval2.ok \
dbugtypedre1.awk \
dbugtypedre1.in \
dbugtypedre1.ok \
@@ -1093,7 +1096,7 @@ UNIX_TESTS = \
GAWK_EXT_TESTS = \
aadelete1 aadelete2 aarray1 aasort aasorti argtest arraysort \
backw badargs beginfile1 beginfile2 binmode1 charasbytes \
- colonwarn clos1way crlf dbugeval dbugtypedre1 dbugtypedre2 delsub \
+ colonwarn clos1way crlf dbugeval dbugeval2 dbugtypedre1 dbugtypedre2 delsub \
devfd devfd1 devfd2 dumpvars errno exit \
fieldwdth fpat1 fpat2 fpat3 fpat4 fpatnull fsfwfs funlen \
functab1 functab2 functab3 fwtest fwtest2 fwtest3 \
@@ -2151,6 +2154,11 @@ dbugtypedre2:
@AWKPATH="$(srcdir)" $(AWK) -D -f $@.awk < "$(srcdir)"/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) "$(srcdir)"/$@.ok _$@ && rm -f _$@
+dbugeval2:
+ @echo $@
+ @AWKPATH="$(srcdir)" $(AWK) -D -f $@.awk < "$(srcdir)"/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
+ @-$(CMP) "$(srcdir)"/$@.ok _$@ && rm -f _$@
+
# Targets generated for other tests:
include Maketests
diff --git a/test/Makefile.in b/test/Makefile.in
index ec270c1b..981b6377 100644
--- a/test/Makefile.in
+++ b/test/Makefile.in
@@ -434,6 +434,9 @@ EXTRA_DIST = \
datanonl.ok \
dbugeval.in \
dbugeval.ok \
+ dbugeval2.awk \
+ dbugeval2.in \
+ dbugeval2.ok \
dbugtypedre1.awk \
dbugtypedre1.in \
dbugtypedre1.ok \
@@ -1349,7 +1352,7 @@ UNIX_TESTS = \
GAWK_EXT_TESTS = \
aadelete1 aadelete2 aarray1 aasort aasorti argtest arraysort \
backw badargs beginfile1 beginfile2 binmode1 charasbytes \
- colonwarn clos1way crlf dbugeval dbugtypedre1 dbugtypedre2 delsub \
+ colonwarn clos1way crlf dbugeval dbugeval2 dbugtypedre1 dbugtypedre2 delsub \
devfd devfd1 devfd2 dumpvars errno exit \
fieldwdth fpat1 fpat2 fpat3 fpat4 fpatnull fsfwfs funlen \
functab1 functab2 functab3 fwtest fwtest2 fwtest3 \
@@ -2586,6 +2589,11 @@ dbugtypedre2:
@echo $@
@AWKPATH="$(srcdir)" $(AWK) -D -f $@.awk < "$(srcdir)"/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
@-$(CMP) "$(srcdir)"/$@.ok _$@ && rm -f _$@
+
+dbugeval2:
+ @echo $@
+ @AWKPATH="$(srcdir)" $(AWK) -D -f $@.awk < "$(srcdir)"/$@.in >_$@ 2>&1 || echo EXIT CODE: $$? >>_$@
+ @-$(CMP) "$(srcdir)"/$@.ok _$@ && rm -f _$@
Gt-dummy:
# file Maketests, generated from Makefile.am by the Gentests program
addcomma:
diff --git a/test/dbugeval2.awk b/test/dbugeval2.awk
new file mode 100644
index 00000000..4997d1b4
--- /dev/null
+++ b/test/dbugeval2.awk
@@ -0,0 +1,4 @@
+BEGIN {
+ a = 2
+ b = 3
+}
diff --git a/test/dbugeval2.in b/test/dbugeval2.in
new file mode 100644
index 00000000..165f7147
--- /dev/null
+++ b/test/dbugeval2.in
@@ -0,0 +1,3 @@
+b 3
+r
+eval "print and(a, 3)"
diff --git a/test/dbugeval2.ok b/test/dbugeval2.ok
new file mode 100644
index 00000000..4d645269
--- /dev/null
+++ b/test/dbugeval2.ok
@@ -0,0 +1,7 @@
+Breakpoint 1 set at file `dbugeval2.awk', line 3
+Starting program:
+Stopping in BEGIN ...
+Breakpoint 1, main() at `dbugeval2.awk':3
+3 b = 3
+2
+EXIT CODE: 2