diff options
Diffstat (limited to 'tests/result.test')
-rw-r--r-- | tests/result.test | 18 |
1 files changed, 18 insertions, 0 deletions
diff --git a/tests/result.test b/tests/result.test index fa21bf7..cefcaed 100644 --- a/tests/result.test +++ b/tests/result.test @@ -114,7 +114,25 @@ test result-6.1 {Bug 1209759} -constraints testreturn -body { # Might panic if bug is not fixed. proc foo {} {catch {return -level 2}; testreturn} foo +} -cleanup { + rename foo {} } -returnCodes ok -result {} +test result-6.2 {Bug 1649062} -setup { + proc foo {} { + if {[catch { + return -code error -errorinfo custom -errorcode CUSTOM foo + } err]} { + return [list $err $::errorCode $::errorInfo] + } + } + set ::errorInfo {} + set ::errorCode {} +} -body { + foo +} -cleanup { + rename foo {} +} -result {foo {} {}} + # cleanup cleanupTests |