diff options
Diffstat (limited to 'Test')
-rw-r--r-- | Test/08traps.ztst | 27 |
1 files changed, 27 insertions, 0 deletions
diff --git a/Test/08traps.ztst b/Test/08traps.ztst index 5ede57fdb..641a50ad2 100644 --- a/Test/08traps.ztst +++ b/Test/08traps.ztst @@ -148,3 +148,30 @@ >end of fn >finish + TRAPZERR() { print 'ERR-or!'; } + f() { print f; false; } + t() { print t; } + f + f && t + t && f && true + t && f + testunset() { + setopt localtraps + unset -f TRAPZERR + print testunset + false + true + } + testunset + f +1: more sophisticated error trapping +>f +>ERR-or! +>f +>t +>t +>f +>ERR-or! +>testunset +>f +>ERR-or! |