diff options
author | ferrieux <ferrieux@users.sourceforge.net> | 2010-04-05 19:44:44 (GMT) |
---|---|---|
committer | ferrieux <ferrieux@users.sourceforge.net> | 2010-04-05 19:44:44 (GMT) |
commit | 068f40511f242f8ead57c0dca5f00b0eba4b6309 (patch) | |
tree | 135ba162a555a418d3cc3bc02fcec17df7d203e2 /tests/result.test | |
parent | b40d694d271c049135dd1a9c6dc276b5de177de2 (diff) | |
download | tcl-068f40511f242f8ead57c0dca5f00b0eba4b6309.zip tcl-068f40511f242f8ead57c0dca5f00b0eba4b6309.tar.gz tcl-068f40511f242f8ead57c0dca5f00b0eba4b6309.tar.bz2 |
TIP #348 IMPLEMENTATION - Substituted error stack
Diffstat (limited to 'tests/result.test')
-rw-r--r-- | tests/result.test | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/result.test b/tests/result.test index b2db8ec..8bde7ef 100644 --- a/tests/result.test +++ b/tests/result.test @@ -135,6 +135,14 @@ test result-6.3 {Bug 2383005} { catch {return -code error -errorcode {{}a} eek} m set m } {bad -errorcode value: expected a list but got "{}a"} +test result-6.4 {non-list -errorstack} { + catch {return -code error -errorstack {{}a} eek} m o + list $m [dict get $o -errorcode] [dict get $o -errorstack] +} {{bad -errorstack value: expected a list but got "{}a"} {TCL RESULT NONLIST_ERRORSTACK} {UP 1}} +test result-6.5 {odd-sized-list -errorstack} { + catch {return -code error -errorstack a eek} m o + list $m [dict get $o -errorcode] [dict get $o -errorstack] +} {{forbidden odd-sized list for -errorstack: "a"} {TCL RESULT ODDSIZEDLIST_ERRORSTACK} {UP 1}} # cleanup cleanupTests return |