summaryrefslogtreecommitdiffstats
path: root/tests/clock.test
diff options
context:
space:
mode:
authorKevin B Kenny <kennykb@acm.org>2009-10-27 03:24:17 (GMT)
committerKevin B Kenny <kennykb@acm.org>2009-10-27 03:24:17 (GMT)
commita648c376f2e2af0c348cd95d5d91171889d16744 (patch)
tree275e600ff3157b078f48c2830eb8dfbf372c421c /tests/clock.test
parent30a3c0dd1ee3d281c2131f4c2a8d13302b594e18 (diff)
downloadtcl-a648c376f2e2af0c348cd95d5d91171889d16744.zip
tcl-a648c376f2e2af0c348cd95d5d91171889d16744.tar.gz
tcl-a648c376f2e2af0c348cd95d5d91171889d16744.tar.bz2
* library/clock.tcl (ParseClockScanFormat):
Corrected a problem where [clock scan] didn't load the timezone soon enough when processing a time format that lacked a complete date. [Bug 2886852] * tests/clock.test (clock-66.1): Added a test case for the above bug.
Diffstat (limited to 'tests/clock.test')
-rw-r--r--tests/clock.test15
1 files changed, 14 insertions, 1 deletions
diff --git a/tests/clock.test b/tests/clock.test
index 32b3e67..bb284c4 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.83.2.7 2009/10/24 22:20:54 kennykb Exp $
+# RCS: @(#) $Id: clock.test,v 1.83.2.8 2009/10/27 03:24:17 kennykb Exp $
if {[lsearch [namespace children] ::tcltest] == -1} {
package require tcltest 2
@@ -36733,6 +36733,19 @@ test clock-65.1 {clock add, bad option [Bug 2481670]} {*}{
-result {bad switch "-foo"*}
}
+test clock-66.1 {clock scan, no date, never-before-seen timezone} {*}{
+ -setup {
+ ::tcl::clock::ClearCaches
+ }
+ -body {
+ clock scan 1200 \
+ -timezone {<EST>+05:00:00<EDT>+04:00:00,M3.2.0/02:00:00,M11.1.0/02:00:00} \
+ -base 1256529600 \
+ -format %H%M
+ }
+ -result 1256572800
+}
+
# cleanup
namespace delete ::testClock