aboutsummaryrefslogtreecommitdiffstats
path: root/test/strftime.awk
diff options
context:
space:
mode:
authorArnold D. Robbins <arnold@skeeve.com>2010-07-16 12:57:07 +0300
committerArnold D. Robbins <arnold@skeeve.com>2010-07-16 12:57:07 +0300
commit3ca7f0b16d0a5c105380b284a81c6a1b2c210908 (patch)
treec2153d226b9cba3ebca0c3556b19bf3e52cd20dd /test/strftime.awk
parentf20ab7c3039a4023f41372bfe4bde3b16d481df7 (diff)
downloadegawk-3ca7f0b16d0a5c105380b284a81c6a1b2c210908.tar.gz
egawk-3ca7f0b16d0a5c105380b284a81c6a1b2c210908.tar.bz2
egawk-3ca7f0b16d0a5c105380b284a81c6a1b2c210908.zip
Move to gawk-3.0.5.
Diffstat (limited to 'test/strftime.awk')
-rw-r--r--test/strftime.awk15
1 files changed, 15 insertions, 0 deletions
diff --git a/test/strftime.awk b/test/strftime.awk
new file mode 100644
index 00000000..8c1f401a
--- /dev/null
+++ b/test/strftime.awk
@@ -0,0 +1,15 @@
+# strftime.awk ; test the strftime code
+#
+# input is the output of `date', see Makefile.in
+#
+# The mucking about with $0 and $N is to avoid problems
+# on cygwin, where the timezone field is empty and there
+# are two consecutive blanks.
+
+{
+ $3 = sprintf("%02d", $3 + 0)
+ print > "strftime.ok"
+ $0 = strftime()
+ $NF = $NF
+ print > OUTPUT
+}