summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorjan.nijtmans <nijtmans@users.sourceforge.net>2020-09-05 21:37:18 (GMT)
committerjan.nijtmans <nijtmans@users.sourceforge.net>2020-09-05 21:37:18 (GMT)
commit0d66de6c27c5b1335c5627436381cd47d0fec5cc (patch)
tree90909b7502c80bab9d58a108fa9f244443fef99b
parent87b0db4d91332f8bf1bd7a58e9a5fb73cc31d8ae (diff)
parent618c49af4d299c9f0d776e604a1c81dd186b3b2d (diff)
downloadtcl-0d66de6c27c5b1335c5627436381cd47d0fec5cc.zip
tcl-0d66de6c27c5b1335c5627436381cd47d0fec5cc.tar.gz
tcl-0d66de6c27c5b1335c5627436381cd47d0fec5cc.tar.bz2
New bug-c1a376375e0e6488 branch with (up to now) failing solutions. Please make sure Travis builds OK before merging to core-8-branch
-rw-r--r--tests/namespace.test96
1 files changed, 0 insertions, 96 deletions
diff --git a/tests/namespace.test b/tests/namespace.test
index d09a853..8209cf3 100644
--- a/tests/namespace.test
+++ b/tests/namespace.test
@@ -618,102 +618,6 @@ test namespace-13.2 {DeleteImportedCmd, Bug a4494e28ed} {
namespace delete src
} {}
-
-test namespace-13.3 {
- deleting origin of import in trace on deletion of import
-} -setup {
- namespace eval ns0 {
- namespace export *
- variable res {}
-
- proc traced {oldname newname op} {
- variable res
-
- lappend res {Is oldname the name of the imported routine?}
- set expected [namespace qualifiers [namespace current]::fake]::ns2::ns1
- if {$oldname eq $expected} {
- lappend res 1
- } else {
- lappend res 0
- }
-
- lappend res {[namespace which] finds the old name}
- set which [namespace which $oldname]
- if {$which eq $expected} {
- lappend res 1
- } else {
- lappend res $which
- }
-
- lappend res {Is origin name correct}
- catch {
- namespace origin $oldname
- } cres copts
- set expected [namespace qualifiers [namespace current]::fake]::ns1
- if {$cres eq $expected} {
- lappend res 1
- } else {
- lappend res $cres
- }
-
- set origin $cres
- rename $origin {}
-
- lappend res {After deletion of the origin is it an error to ask for the origin (compiled)?}
- set status [catch {
- namespace origin $oldname
- } cres copts]
- if {$status && [string match {invalid command name "*::ns2::ns1"} $cres]} {
- lappend res 1
- } else {
- lappend res $cres
- }
-
- lappend res {After deletion of the origin is it an error to ask for the origin (uncompiled)?}
- set status [catch {
- namespace eval [namespace current] "namespace origin $oldname"
- } cres copts]
- if {$status && [string match {invalid command name "*::ns2::ns1"} $cres]} {
- lappend res 1
- } else {
- lappend res $cres
- }
-
- lappend res {after deletion of origin, [namespace which] on the imported routine returns the empty string}
- set which [namespace which $oldname]
- if {$which eq {}} {
- lappend res 1
- } else {
- lappend res $which
- }
-
- return
- }
-
- }
-} -body {
- namespace eval ns0::ns1 {
- namespace ensemble create
- }
-
- namespace eval ns0::ns2 {
- namespace import [namespace parent]::ns1
- trace add command ns1 delete [namespace parent]::traced
- rename ns1 {}
- }
- return $ns0::res
-} -cleanup {
- namespace delete ns0
-} -result [list \
- {Is oldname the name of the imported routine?} 1 \
- {[namespace which] finds the old name} 1 \
- {Is origin name correct} 1 \
- {After deletion of the origin is it an error to ask for the origin (compiled)?} 1 \
- {After deletion of the origin is it an error to ask for the origin (uncompiled)?} 1 \
- {after deletion of origin, [namespace which] on the imported routine returns the empty string} 1 \
-]
-
-
test namespace-14.1 {TclGetNamespaceForQualName, absolute names} -setup {
catch {namespace delete {*}[namespace children :: test_ns_*]}
variable v 10