Skip to content
Tcl Source Code View Ticket
Login

View Ticket

2004-09-08
23:11 • Closed ticket [1023779fff]: Some tests from clock.test fail under XP plus 7 ... artifact: d70797b96f user: kennykb
00:47 • Ticket [1023779fff]: 5 changes artifact: 6c149c38a9 user: kennykb
2004-09-07
15:46 • New ticket [1023779fff]. artifact: 7435f903e7 user: hgiese

Some tests from clock.test fail under XP

Closed / Fixed1023779fffffffffffffffffffffffffffffffffCreated 22 years agoUpdated 22 years ago
Descriptionplain2004-09-07 15:46:27
Hello everybody,
the following tests fail when run under XP (but pass
under Win98 - same machine, just booting differently).
Results:

---- Result was:
Oct 23,1992 14:00
---- Result should have been (exact matching):
Oct 23,1992 15:00
==== clock-34.6 FAILED

---- Result was:
Oct 21, 1992
---- Result should have been (exact matching):
Oct 22, 1992
==== clock-34.12 FAILED

---- Result was:
Oct 22, 1992
---- Result should have been (exact matching):
Oct 23, 1992
==== clock-34.13 FAILED

---- Result was:
Oct 22, 1992
---- Result should have been (exact matching):
Oct 23, 1992
==== clock-34.14 FAILED

---- Result was:
Oct 22, 1992
---- Result should have been (exact matching):
Oct 23, 1992
==== clock-34.15 FAILED

---- Result was:
Oct 23, 1992 22:59:59
---- Result should have been (exact matching):
Oct 23, 1992 23:59:59
==== clock-34.16 FAILED

---- Result was:
Oct 23, 1992 22:59:59
---- Result should have been (exact matching):
Oct 23, 1992 23:59:59
==== clock-34.17 FAILED

---- Result was:
Oct 22, 1992 23:00:00
---- Result should have been (exact matching):
Oct 23, 1992 00:00:00
==== clock-34.18 FAILED

Tests 34.7, 34.8, 34.10 and 34.11 failed because a time
zone :GMT could not be found (as did many others -
failing to find either :GMT or :UTC). Looking at the
sources I got the impression that this could be due to
some re-structuring (e.g. file .../tzdata/utc wants to
call 'loadTimeZoneFile' but I only found
'LoadTimeZoneFile' in clock.tcl - note the capital 'L'.
So it doesn't surprise me that these occur under XP as
well as under Win98.)

The above results seem to be independent of the
compiler used - same results whether compiled with
Borland or VC.
Let me know if you need further information or want me
to run some tests.
Best regards
Helmut Giese
kennykbplain2004-09-08 00:47:03
Logged In: YES 
user_id=99768

The problem with the :GMT time zone is fixed - it was a missed
change in tools/tclZIC.tcl.  Several of your other reported
problems
are also fixed in my latest commit.

clock-34.{6,12,13,14,15,16,17,18} appear to be a bug in the
legacy free-format [clock scan]. It's not clear to me that
the bug
is fixable without breaking something else. I'm going to leave
this item open for further investigation, but downgrade its
priority.
kennykbplain2004-09-08 23:11:13
Logged In: YES 
user_id=99768

The clock-34.* tests were hitting a truly weird problem.

The legacy [clock scan] uses the C library to determine
whether the date in question is in summer or winter time
(and, in fact, to do all the time conversions).  The
strftime and mktime routines in the VC (and presumably
Borland) libraries have a missing feature that they can't
cope with changes of the rules.  Back in 1992, Summer
Time ended in the EU on the last Sunday of September,
but the C library incorrectly applies the current rule to
the historic time.

The fix in the test cases is to use -timezone :localtime,
so that both input and output conversions use the C
library code, and that's what I've done.  But what would
really be desirable is to refactor TclGetDate so that
the Convert procedure is eliminated and the raw fields
from the YACC parse are returned.

The problem is greatly complicated by the fact that
'make gendate' is broken again - as far as I can tell,
it does not even work on Solaris any more.  So before
I can tackle that one, I need to revise the build system
for TclGetDate yet again.  Oh, joy.

In any case, the test failures are silenced, so I'm
closing this bug.
Log in (anonymous is fine) to add a comment.