aboutsummaryrefslogtreecommitdiffstats
path: root/test/rwarray.awk
diff options
context:
space:
mode:
Diffstat (limited to 'test/rwarray.awk')
-rw-r--r--test/rwarray.awk11
1 files changed, 11 insertions, 0 deletions
diff --git a/test/rwarray.awk b/test/rwarray.awk
index c06fec21..dfd74ce0 100644
--- a/test/rwarray.awk
+++ b/test/rwarray.awk
@@ -11,6 +11,9 @@ BEGIN {
split("-2.4", f)
dict[strnum_sub] = f[1]
+ bool_sub = "bool-sub"
+ dict[bool_sub] = mkbool(1)
+
dict["x"] = "x"
dict["42"] = 42
@@ -56,4 +59,12 @@ BEGIN {
if (typeof(dict[strnum_sub]) != "strnum")
printf("dict[\"%s\"] should be strnum, is %s\n",
strnum_sub, typeof(dict[strnum_sub]));
+
+ if (typeof(dict[bool_sub]) != "number|bool")
+ printf("dict[\"%s\"] should be number|bool, is %s\n",
+ bool_sub, typeof(dict[bool_sub]));
+
+ if ((dict[bool_sub] "") != "1")
+ printf("dict[\"%s\"] should be 1, is %s\n",
+ bool_sub, dict[bool_sub]);
}