Lines Matching defs:err_exit

20 function err_exit
26 alias err_exit='err_exit $LINENO'
31 tmp=$(mktemp -dt) || { err_exit mktemp -dt failed; exit 1; }
59 [[ $z == "$val" ]] || err_exit 'compound variable with mixed arrays not working'
61 [[ ${z.bar[1]} == yesyes ]] || err_exit 'reassign of index array compound variable fails'
63 [[ ${z.bar[1]} == $'(\n\tx=12\n\ty=5\n)' ]] || err_exit 'reassign array simple to compound variable fails'
67 [[ ${z.foo[three]} == good ]] || err_exit 'associative array assignment in subshell not working'
69 [[ $z == "$val" ]] || err_exit 'compound variable changes after associative array assignment'
74 [[ ${z.foo[two]} == ok ]] || err_exit 'associative array assignment to compound variable in subshell not working'
76 [[ ${z.bar[1]} == yes ]] || err_exit 'index array assignment to compound variable in subshell not working'
78 [[ $z == "$val" ]] || err_exit 'compound variable changes after associative array assignment'
87 [[ ${x.foo.qqq} ]] && err_exit 'x.foo.qqq should be unset'
89 [[ ${x.foo} == good ]] || err_exit 'x.foo should be good'
91 [[ $x == "$val" ]] || err_exit 'compound variable changes after unset leaves'
96 [[ ${l+foo} != foo ]] || err_exit 'l should be unset'
118 (( no == (BS * nb) )) || err_exit "shell hangs on command substitution output size >= $BS*$nb with write size $bs -- expected $((BS*nb)), got ${no:-0}"
133 (( no == (BS * nb) )) || err_exit "shell hangs on command substitution output size >= $BS*$nb with write size $bs and trailing redirection -- expected $((BS*nb)), got ${no:-0}"
172 then err_exit "${TEST_shell/*-c/\$SHELL -c} ${TEST_unset:+unset }${TEST_fork:+fork }$txt print failed"
176 err_exit "${TEST_shell/*-c/\$SHELL -c} ${TEST_unset:+unset }${TEST_fork:+fork }$txt command substitution failed -- expected $EXP, got $GOT"
199 [[ $r == ok ]] || err_exit "large subshell command substitution hangs"
219 [[ $r == ok ]] || err_exit "shell hangs on $TEST_test"
227 $SHELL -c '( autoload xxxxx);print -n' || err_exit 'autoloaded functions in subshells can cause failure'
232 [[ $foo == foobar ]] || err_exit 'trap on exit when last commands is subshell is not triggered'
255 err_exit "nested command substitution with redirections failed -- $err"
268 [[ $got == $exp ]] || err_exit "getopts --man runtime callout with nonzero exit terminates shell -- expected '$exp', got '$got'"
278 [[ $got == $exp ]] || err_exit "getopts --man runtime callout with nonzero exit terminates shell -- expected '$exp', got '$got'"
317 then err_exit "test $TEST '$1...$2 exit $code' failed -- exit status $status, expected $code"
319 then err_exit "test $TEST '$1...$2 exit $code' failed -- got '$got', expected '$exp'"
406 err_exit "'x=${SUB[S].BEG}${INS[I]}${cmd}${APP[A]}${SUB[S].END} && print \${#x}' failed -- expected '$exp', got '$got'"
439 then err_exit "eval '$cmd' failed -- expected '$exp', got '$got'"
447 (( (SECONDS-t1) > 4 )) && err_exit '/bin/sleep& in subshell hanging'
451 (( (SECONDS-t1) > 4 )) && err_exit 'sleep& in subshell hanging'
456 [[ $got == "$exp" ]] || err_exit "( HOME=/bin/sh ) cleanup failed -- expected '$exp', got '$got'"
461 [[ $got == "$exp" ]] || err_exit "'$cmd' failed -- expected '$exp', got '$got'"
469 err_exit "'$cmd' failed -- expected $EXP, got $GOT"