From d234059b1c6493e5eefb6c28aa2b8a021d894d51 Mon Sep 17 00:00:00 2001 From: pdpennock Date: Sun, 10 Oct 2010 00:05:24 +0000 Subject: 28338: keep =~ from inverting sense of subsequent tests (after &&/||) --- Test/C02cond.ztst | 13 +++++++++++++ 1 file changed, 13 insertions(+) (limited to 'Test/C02cond.ztst') diff --git a/Test/C02cond.ztst b/Test/C02cond.ztst index 2d4204038..00e22c182 100644 --- a/Test/C02cond.ztst +++ b/Test/C02cond.ztst @@ -283,6 +283,19 @@ F:Failures in these cases do not indicate a problem in the shell. print OK fi) 0:MATCH, MBEGIN, MEND, match, mbegin, mend +>OK + + (if zmodload -i zsh/regex 2>/dev/null; then + if [[ a =~ a && b == b ]]; then + print OK + else + print "regex =~ inverted following test" + fi + else + # not a test error + print OK + fi) +0:regex infix operator should not invert following conditions >OK [[ -fail badly ]] -- cgit 1.4.1