diff options
author | dgp <dgp@users.sourceforge.net> | 2007-08-14 15:15:37 (GMT) |
---|---|---|
committer | dgp <dgp@users.sourceforge.net> | 2007-08-14 15:15:37 (GMT) |
commit | 92e2a909349132a063e8f44d0be1b2f419279f7e (patch) | |
tree | 8e7298933ba43047b1d731533bd45bc2f7d8c849 | |
parent | 720f2ebb87f3a202b571853c506692b847edc023 (diff) | |
download | tcl-92e2a909349132a063e8f44d0be1b2f419279f7e.zip tcl-92e2a909349132a063e8f44d0be1b2f419279f7e.tar.gz tcl-92e2a909349132a063e8f44d0be1b2f419279f7e.tar.bz2 |
* tests/trace.test: Backport some tests.
-rw-r--r-- | ChangeLog | 4 | ||||
-rw-r--r-- | tests/trace.test | 28 |
2 files changed, 31 insertions, 1 deletions
@@ -1,3 +1,7 @@ +2007-08-14 Don Porter <dgp@users.sourceforge.net> + + * tests/trace.test: Backport some tests. + 2007-08-14 Daniel Steffen <das@users.sourceforge.net> * unix/tclLoadDyld.c: use dlfcn API on Mac OS X 10.4 and later; fix diff --git a/tests/trace.test b/tests/trace.test index 32e1b4e..362a505 100644 --- a/tests/trace.test +++ b/tests/trace.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: trace.test,v 1.26.2.17 2006/11/04 01:37:56 msofer Exp $ +# RCS: @(#) $Id: trace.test,v 1.26.2.18 2007/08/14 15:15:39 dgp Exp $ if {[lsearch [namespace children] ::tcltest] == -1} { package require tcltest @@ -230,6 +230,32 @@ test trace-2.5 {trace variable writes} { unset x set info } {} +test trace-2.6 {trace variable writes on compiled local} { + # + # Check correct function of whole array traces on compiled local + # arrays [Bug 1770591]. The corresponding function for read traces is + # already indirectly tested in trace-1.7 + # + catch {unset x} + set info {} + proc p {} { + trace add variable x write traceArray + set x(X) willy + } + p + set info +} {x X write 0 willy} +test trace-2.7 {trace variable writes on errorInfo} -body { + # + # Check correct behaviour of write traces on errorInfo. + # [Bug 1773040] + trace add variable ::errorInfo write traceScalar + catch {set dne} + lrange [set info] 0 2 +} -cleanup { + # always remove trace on errorInfo otherwise further tests will fail + unset ::errorInfo +} -result {::errorInfo {} write} # append no longer triggers read traces when fetching the old values of # variables before doing the append operation. However, lappend _does_ |