summaryrefslogtreecommitdiff
path: root/testsuite/tests/lib
diff options
context:
space:
mode:
Diffstat (limited to 'testsuite/tests/lib')
-rw-r--r--testsuite/tests/lib/Time/T5430.hs8
-rw-r--r--testsuite/tests/lib/Time/T5430.stdout1
-rw-r--r--testsuite/tests/lib/Time/all.T1
3 files changed, 10 insertions, 0 deletions
diff --git a/testsuite/tests/lib/Time/T5430.hs b/testsuite/tests/lib/Time/T5430.hs
new file mode 100644
index 0000000000..b011ed61ea
--- /dev/null
+++ b/testsuite/tests/lib/Time/T5430.hs
@@ -0,0 +1,8 @@
+
+import System.Locale
+import System.Time
+
+main :: IO ()
+main = do let clockTime = TOD 0 0 -- 00:00:00 on 1 Jan 1970
+ calTime <- toCalendarTime clockTime
+ putStrLn $ formatCalendarTime defaultTimeLocale "%j" calTime
diff --git a/testsuite/tests/lib/Time/T5430.stdout b/testsuite/tests/lib/Time/T5430.stdout
new file mode 100644
index 0000000000..5325a8dff7
--- /dev/null
+++ b/testsuite/tests/lib/Time/T5430.stdout
@@ -0,0 +1 @@
+001
diff --git a/testsuite/tests/lib/Time/all.T b/testsuite/tests/lib/Time/all.T
index 25b40820c0..3b310b416e 100644
--- a/testsuite/tests/lib/Time/all.T
+++ b/testsuite/tests/lib/Time/all.T
@@ -1,3 +1,4 @@
test('time002', normal, compile_and_run, [''])
test('time003', normal, compile_and_run, [''])
test('time004', normal, compile_and_run, [''])
+test('T5430', normal, compile_and_run, [''])