summaryrefslogtreecommitdiffstats
path: root/tests/clock.test
diff options
context:
space:
mode:
authorKevin B Kenny <kennykb@acm.org>2004-12-29 20:57:25 (GMT)
committerKevin B Kenny <kennykb@acm.org>2004-12-29 20:57:25 (GMT)
commitf68ab6508b8355f713be6c3005204bbab14717aa (patch)
tree443fafc914ab6f557d09f08d00406daa7772ee6e /tests/clock.test
parent3c1e7bd70247b897a1e6f47d8fcb6d50de880aea (diff)
downloadtcl-f68ab6508b8355f713be6c3005204bbab14717aa.zip
tcl-f68ab6508b8355f713be6c3005204bbab14717aa.tar.gz
tcl-f68ab6508b8355f713be6c3005204bbab14717aa.tar.bz2
bugs 1090413, 1092789 fixed
Diffstat (limited to 'tests/clock.test')
-rw-r--r--tests/clock.test26
1 files changed, 25 insertions, 1 deletions
diff --git a/tests/clock.test b/tests/clock.test
index b5c19fb..7cd4509 100644
--- a/tests/clock.test
+++ b/tests/clock.test
@@ -11,7 +11,7 @@
# See the file "license.terms" for information on usage and redistribution
# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
#
-# RCS: @(#) $Id: clock.test,v 1.52 2004/11/30 15:45:04 kennykb Exp $
+# RCS: @(#) $Id: clock.test,v 1.53 2004/12/29 20:57:28 kennykb Exp $
if {[lsearch [namespace children] ::tcltest] == -1} {
package require tcltest 2
@@ -35375,6 +35375,30 @@ test clock-45.1 {regression test - time zone containing only two digits} \
} \
-result 482134530
+test clock-46.1 {regression test - month zero} \
+ -body {
+ clock scan 2004-00-00 -format %Y-%m-%d
+ } -result [clock scan 2003-11-30 -format %Y-%m-%d]
+test clock-46.2 {regression test - month zero} \
+ -body {
+ clock scan 20040000
+ } -result [clock scan 2003-11-30 -format %Y-%m-%d]
+test clock-46.3 {regression test - month thirteen} \
+ -body {
+ clock scan 2004-13-01 -format %Y-%m-%d
+ } -result [clock scan 2005-01-01 -format %Y-%m-%d]
+test clock-46.4 {regression test - month thirteen} \
+ -body {
+ clock scan 20041301
+ } -result [clock scan 2005-01-01 -format %Y-%m-%d]
+
+test clock-47.1 {regression test - four-digit time} {
+ clock scan 0012
+} [clock scan 0012 -format %H%M]
+test clock-47.2 {regression test - four digit time} {
+ clock scan 0039
+} [clock scan 0039 -format %H%M]
+
# cleanup
namespace delete ::testClock