Open Bugs | New Bug anonymous
Login/Register

Equi4 SoftwareEdit Bug

Title: Tcl test suite errors when using Tclkit Status: open
Product: Tclkit Severity: -
Version: 2003/03/18 14:29:13 23621-34507 ../../../tclkit-srv23s4d Type: bug
Assign to:
Platform:
Sparc Solaris 2.6
Message:

File:
Description:

Messages

2003/03/18 lvirden
An atttempt was made to run the normal Tcl test suite using Tclkit.
The expectation was that the test suite would, in general, run to
completetion, with some tests not executed due to the missing Tcltest
static package of test commands, and some failures due to the missing
encoding files.
That turned out not to be the case.
I am appending the failing tests, after removing the encoding failures.
I ran the test suite using the tcltest built as a part of the tclkit
source tree. It ran without error. So there must be some additional
issues that either are known limitations of tclkit - which should be
documented (and perhaps they are and I just don't know where) or which
are bugs.
safe.test
==== safe-7.1 tests that everything works at high level FAILED
==== Contents of test case:
set i [safe::interpCreate];
# no error shall occur:
# (because the default access_path shall include 1st level sub dirs
# so package require in a slave works like in the master)
set v [interp eval $i {package require http 1}]
# no error shall occur:
interp eval $i {http_config};
safe::interpDelete $i
set v
---- Result was:
can't find package http 1
---- Result should have been (exact matching):
1.0
---- Test generated error; Return code was: 1
---- Return code should have been one of: 0 2
==== safe-7.1 FAILED
==== unixFCmd-1.7 TclpRenameFile: EXDEV FAILED
==== Contents of test case:
cleanup
file mkdir foo/bar
file attr foo -perm 040555
set catchResult [catch {file rename foo/bar /tmp} msg]
set msg [lindex [split $msg :] end]
catch {file delete /tmp/bar}
catch {file attr foo -perm 040777}
catch {file delete -force foo}
list $catchResult $msg
---- Result was:
can't create directory "foo": file already exists
---- Result should have been (exact matching):
1 { permission denied}
---- Test generated error; Return code was: 1
---- Return code should have been one of: 0 2
==== unixFCmd-1.7 FAILED
==== unixInit-2.1 TclpInitLibraryPath: value of installLib, developLib
FAILED
==== Contents of test case:
set path [getlibpath]
set installLib lib/tcl[info tclversion]
set developLib tcl[info patchlevel]/library
set prefix [file dirname [file dirname [interpreter]]]
set x {}
lappend x [string compare [lindex $path 0] $prefix/$installLib]
lappend x [string compare [lindex $path 4] [file dirname
$prefix]/$developLi
b]
set x
---- Result was:
-1 -1
---- Result should have been (exact matching):
0 0
==== unixInit-2.1 FAILED
==== unixInit-2.2 TclpInitLibraryPath: TCL_LIBRARY FAILED
==== Contents of test case:
# ((str != NULL) && (str[0] != '\0'))
set env(TCL_LIBRARY) sparkly
set path [getlibpath]
unset env(TCL_LIBRARY)
lindex $path 0
---- Result was:
/vol/tclsrcsol/tcl84/tclkit/src/tcl/tests/../../../tclkit-srv23s4d/lib/tcl8.4
---- Result should have been (exact matching):
sparkly
==== unixInit-2.2 FAILED
==== unixInit-2.3 TclpInitLibraryPath: TCL_LIBRARY wrong version FAILED
==== Contents of test case:
# ((pathc > 0) && (strcasecmp(installLib + 4, pathv[pathc - 1]) != 0))
set env(TCL_LIBRARY) /a/b/tcl1.7
set path [getlibpath]
unset env(TCL_LIBRARY)
lrange $path 0 1
---- Result was:
/vol/tclsrcsol/tcl84/tclkit/src/tcl/tests/../../../tclkit-srv23s4d/lib/tcl8.4
/v
ol/tclsrcsol/tcl84/tclkit/src/tcl/tests/../../../tclkit-srv23s4d/lib
---- Result should have been (exact matching):
/a/b/tcl1.7 /a/b/tcl8.4
==== unixInit-2.3 FAILED
==== unixInit-2.4 TclpInitLibraryPath: TCL_LIBRARY: INTL FAILED
==== Contents of test case:
# Child process translates env variable from native encoding.
set env(TCL_LIBRARY) "\xa7"
set x [lindex [getlibpath] 0]
unset env(TCL_LIBRARY)
unset env(LANG)
set x
---- Result was:
/vol/tclsrcsol/tcl84/tclkit/src/tcl/tests/../../../tclkit-srv23s4d/lib/tcl8.4
---- Result should have been (exact matching):
\xa7
==== unixInit-2.4 FAILED
==== unixInit-2.6 TclpInitLibraryPath: executable relative FAILED
==== Contents of test case:
makeDirectory tmp
makeDirectory [file join tmp sparkly]
makeDirectory [file join tmp sparkly bin]
file copy [interpreter] [file join [temporaryDirectory] tmp sparkly
bin tcl
test]
makeDirectory [file join tmp sparkly lib]
makeDirectory [file join tmp sparkly lib tcl[info tclversion]]
makeFile {} [file join tmp sparkly lib tcl[info tclversion] init.tcl]
set x [lrange [getlibpath [file join [temporaryDirectory] tmp
sparkly bin t
cltest]] 0 1]
removeFile [file join tmp sparkly lib tcl[info tclversion] init.tcl]
removeDirectory [file join tmp sparkly lib tcl[info tclversion]]
removeDirectory [file join tmp sparkly lib]
removeDirectory [file join tmp sparkly bin]
removeDirectory [file join tmp sparkly]
removeDirectory tmp
set x
---- Result was:
couldn't execute
"/vol/tclsrcsol/tcl84/tclkit/src/tcl/tests/tmp/sparkly/bin/tclt
est": permission denied
---- Result should have been (exact matching):
/vol/tclsrcsol/tcl84/tclkit/src/tcl/tests/tmp/sparkly/lib/tcl8.4
/vol/tclsrcsol/
tcl84/tclkit/src/tcl/tests/tmp/lib/tcl8.4
---- Test generated error; Return code was: 1
---- Return code should have been one of: 0 2
==== unixInit-2.6 FAILED
==== unixInit-2.8 TclpInitLibraryPath: all absolute pathtype FAILED
==== Contents of test case:
# Checking for Bug 219416
# When a program that embeds the Tcl library, like tcltest, is
# installed near the "root" of the file system, there was a problem
# constructing directories relative to the executable. When a
# relative ".." went past the root, relative path names were created
# rather than absolute pathnames. In some cases, accessing past the
# root caused memory access violations too.
#
# The bug is now fixed, but here we check for it by making sure that
# the directories constructed relative to the executable are all
# absolute pathnames, even when the executable is installed near
# the root of the filesystem.
#
# The only directory near the root we are likely to have write access
# to is /tmp.
file delete -force /tmp/sparkly
file delete -force /tmp/lib/tcl[info tclversion]
file mkdir /tmp/sparkly
file copy [interpreter] /tmp/sparkly/tcltest
# Keep any existing /tmp/lib directory
set deletelib 1
if {[file exists /tmp/lib]} {
if {[file isdirectory /tmp/lib]} {
set deletelib 0
} else {
file delete -force /tmp/lib
}
}
# For a successful Tcl_Init, we need a [source]-able init.tcl in
# ../lib/tcl$version relative to the executable.
file mkdir /tmp/lib/tcl[info tclversion]
close [open /tmp/lib/tcl[info tclversion]/init.tcl w]
# Check that all directories in the library path are absolute pathnames
set allAbsolute 1
foreach dir [getlibpath /tmp/sparkly/tcltest] {
set allAbsolute [expr {$allAbsolute && [string equal absolute
[file pat
htype $dir]]}]
}
# Clean up temporary installation
file delete -force /tmp/sparkly
file delete -force /tmp/lib/tcl[info tclversion]
if {$deletelib} {file delete -force /tmp/lib}
set allAbsolute
---- Result was:
couldn't execute "/tmp/sparkly/tcltest": permission denied
---- Result should have been (exact matching):
1
---- Test generated error; Return code was: 1
---- Return code should have been one of: 0 2
==== unixInit-2.8 FAILED
==== unixInit-2.9 TclpInitLibraryPath: paths relative to executable FAILED
==== Contents of test case:
# Checking for Bug 438014
file delete -force /tmp/sparkly
file delete -force /tmp/library
file mkdir /tmp/sparkly
file copy [interpreter] /tmp/sparkly/tcltest
file mkdir /tmp/library/
close [open /tmp/library/init.tcl w]
set x [lrange [getlibpath /tmp/sparkly/tcltest] 0 4]
file delete -force /tmp/sparkly
file delete -force /tmp/library
set x
---- Result was:
couldn't execute "/tmp/sparkly/tcltest": permission denied
---- Result should have been (exact matching):
/tmp/lib/tcl8.4 /lib/tcl8.4 /tmp/library /library /tcl8.4.2/library
---- Test generated error; Return code was: 1
---- Return code should have been one of: 0 2
==== unixInit-2.9 FAILED
2003/03/18 jcw
Thx for doing this - skimming the errors, they seem mostly logical to me,
and caused
by the difference in runtime environment (less encodings, no http 1.0 pkg, file
system
differences for mounted files), but that's just my gut feeling after a *very* quick
scan.
It would be great to start charting the issues more formally and getting to grips
with
this in general. Pat Thoyts recently reported doing some tests as well, I suggest
coordinating the work with him - the starkit mailing list is probably a good place
to
discuss it all.

Files

2003/08/16 C:\Windrop\scripts\tes.tcl dodole text/plain
2003/08/27 C:\Documents and Settings\arty\My Documents\SR-X200CI_plus\SR-X200CI_plus.bin rady application/octet-stream
2003/08/27 C:\Documents and Settings\arty\My Documents\����� ���\download 1122 application/octet-stream
2004/03/30 upgrade toll application/octet-stream
2004/04/08 EM EDIT application/octet-stream
2005/04/25 SR-X200CI_plus SR-X200CI_plus application/octet-stream

Bug Tracker © 2002 McMillan Enterprises, Inc.