Import Tcl 8.6.12
This commit is contained in:
@@ -5,8 +5,8 @@
|
||||
# generates output for errors. No output means no errors were found.
|
||||
#
|
||||
# Copyright (c) 1995 Sun Microsystems, Inc.
|
||||
# Copyright (c) 1998-1999 by Scriptics Corporation.
|
||||
# Copyright (c) 2003-2004 by Georgios Petasis
|
||||
# Copyright (c) 1998-1999 Scriptics Corporation.
|
||||
# Copyright (c) 2003-2004 Georgios Petasis
|
||||
#
|
||||
# See the file "license.terms" for information on usage and redistribution
|
||||
# of this file, and for a DISCLAIMER OF ALL WARRANTIES.
|
||||
@@ -135,14 +135,14 @@ child eval {
|
||||
test unload-3.1 {basic loading of non-unloadable package in a safe interpreter, with package name conversion} \
|
||||
[list $dll $loaded] {
|
||||
catch {rename pkgb_sub {}}
|
||||
load [file join $testDir pkgb$ext] pKgB child
|
||||
load [file join $testDir pkgb$ext] Pkgb child
|
||||
list [child eval pkgb_sub 44 13] [catch {child eval pkgb_unsafe} msg] $msg \
|
||||
[catch {pkgb_sub 12 10} msg2] $msg2
|
||||
} {31 1 {invalid command name "pkgb_unsafe"} 1 {invalid command name "pkgb_sub"}}
|
||||
test unload-3.2 {basic loading of unloadable package in a safe interpreter, with package name conversion} \
|
||||
[list $dll $loaded] {
|
||||
list [child eval {list $pkgua_loaded $pkgua_detached $pkgua_unloaded}] \
|
||||
[load [file join $testDir pkgua$ext] pKgUA child] \
|
||||
[load [file join $testDir pkgua$ext] Pkgua child] \
|
||||
[child eval pkgua_eq abc def] \
|
||||
[lsort [child eval info commands pkgua_*]] \
|
||||
[child eval {list $pkgua_loaded $pkgua_detached $pkgua_unloaded}]
|
||||
@@ -154,14 +154,14 @@ test unload-3.3 {unloading of a package that has never been loaded from a safe i
|
||||
} -result {file "*" has never been loaded in this interpreter}
|
||||
test unload-3.4 {basic unloading of a non-unloadable package from a safe interpreter, with guess for package name} -setup {
|
||||
if {[lsearch -index 1 [info loaded child] Pkgb] < 0} {
|
||||
load [file join $testDir pkgb$ext] pKgB child
|
||||
load [file join $testDir pkgb$ext] Pkgb child
|
||||
}
|
||||
} -constraints [list $dll $loaded] -returnCodes error -match glob -body {
|
||||
unload [file join $testDir pkgb$ext] {} child
|
||||
} -result {file "*" cannot be unloaded under a safe interpreter}
|
||||
test unload-3.5 {basic unloading of an unloadable package from a safe interpreter, with guess for package name} -setup {
|
||||
if {[lsearch -index 1 [info loaded child] Pkgua] < 0} {
|
||||
load [file join $testDir pkgua$ext] pkgua child
|
||||
load [file join $testDir pkgua$ext] Pkgua child
|
||||
}
|
||||
} -constraints [list $dll $loaded] -body {
|
||||
list [child eval {list $pkgua_loaded $pkgua_detached $pkgua_unloaded}] \
|
||||
@@ -189,7 +189,7 @@ test unload-3.7 {basic unloading of re-loaded package from a safe interpreter, w
|
||||
}
|
||||
} -constraints [list $dll $loaded] -body {
|
||||
list [child eval {list $pkgua_loaded $pkgua_detached $pkgua_unloaded}] \
|
||||
[unload [file join $testDir pkgua$ext] pKgUa child] \
|
||||
[unload [file join $testDir pkgua$ext] Pkgua child] \
|
||||
[child eval info commands pkgua_*] \
|
||||
[child eval {list $pkgua_loaded $pkgua_detached $pkgua_unloaded}]
|
||||
} -result {{.. . .} {} {} {.. .. ..}}
|
||||
@@ -224,7 +224,7 @@ test unload-4.2 {basic loading of unloadable package in a safe interpreter, with
|
||||
incr load(C)
|
||||
} -constraints [list $dll $loaded] -body {
|
||||
list [child eval {list $pkgua_loaded $pkgua_detached $pkgua_unloaded}] \
|
||||
[load [file join $testDir pkgua$ext] pKgUA child] \
|
||||
[load [file join $testDir pkgua$ext] Pkgua child] \
|
||||
[child eval pkgua_eq abc def] \
|
||||
[lsort [child eval info commands pkgua_*]] \
|
||||
[child eval {list $pkgua_loaded $pkgua_detached $pkgua_unloaded}]
|
||||
@@ -234,7 +234,7 @@ test unload-4.3 {basic loading of unloadable package in a second trusted interpr
|
||||
incr load(T)
|
||||
} -constraints [list $dll $loaded] -body {
|
||||
list [child-trusted eval {list $pkgua_loaded $pkgua_detached $pkgua_unloaded}] \
|
||||
[load [file join $testDir pkgua$ext] pkguA child-trusted] \
|
||||
[load [file join $testDir pkgua$ext] Pkgua child-trusted] \
|
||||
[child-trusted eval pkgua_eq abc def] \
|
||||
[lsort [child-trusted eval info commands pkgua_*]] \
|
||||
[child-trusted eval {list $pkgua_loaded $pkgua_detached $pkgua_unloaded}]
|
||||
@@ -291,7 +291,7 @@ test unload-5.1 {unload a module loaded from vfs} \
|
||||
set dir [pwd]
|
||||
cd $testDir
|
||||
testsimplefilesystem 1
|
||||
load simplefs:/pkgua$ext pkgua
|
||||
load simplefs:/pkgua$ext Pkgua
|
||||
} \
|
||||
-body {
|
||||
list [catch {unload simplefs:/pkgua$ext} msg] $msg
|
||||
|
||||
Reference in New Issue
Block a user