Files
mercury/tests/hard_coded/dst_test.exp
James Goddard cb04e37f22 Revised the test cases for the time library.
Estimated hours taken: 3
Branches: main

Revised the test cases for the time library.

tests/time_test.m:
	mktime(localtime(Time)) is now considered to be close enough to the
	original Time if it is less than 1 second earlier.

tests/dst_test.m:
	Tests daylight savings time is implemented correctly.
	Also tests localtime vs gmtime on the changeover dates.

tests/dst_test.exp:
	corresponding expected output.

tests/Mmakefile:
	Added dst_test to the list.
	Added rule for dst_test, which sets the TZ environmental variable
	to 'Australia/Melbourne' before running the test.
2003-12-17 05:32:16 +00:00

32 lines
787 B
Plaintext

start DST succeeded
end DST succeeded
Local: Sun Oct 26 01:59:00 2003
GMT: Sat Oct 25 15:59:00 2003
Local: Sun Oct 26 03:00:00 2003
GMT: Sat Oct 25 16:00:00 2003
Local: Sun Oct 26 03:01:00 2003
GMT: Sat Oct 25 16:01:00 2003
Local: Sun Mar 28 01:59:00 2004
GMT: Sat Mar 27 14:59:00 2004
Local: Sun Mar 28 02:00:00 2004
GMT: Sat Mar 27 15:00:00 2004
Local: Sun Mar 28 02:01:00 2004
GMT: Sat Mar 27 15:01:00 2004
Local: Sun Mar 28 02:59:00 2004
GMT: Sat Mar 27 15:59:00 2004
Local: Sun Mar 28 02:00:00 2004
GMT: Sat Mar 27 16:00:00 2004
Local: Sun Mar 28 02:01:00 2004
GMT: Sat Mar 27 16:01:00 2004
Local: Sun Mar 28 02:59:00 2004
GMT: Sat Mar 27 16:59:00 2004
Local: Sun Mar 28 03:00:00 2004
GMT: Sat Mar 27 17:00:00 2004
Local: Sun Mar 28 03:01:00 2004
GMT: Sat Mar 27 17:01:00 2004