`output' expectation handler using aok for PIPESTATUS check

stderr
Mike Gerwitz 2014-05-12 22:16:06 -04:00
parent 8957aad72d
commit a1f09855c0
1 changed files with 3 additions and 2 deletions

View File

@ -22,6 +22,8 @@
[ -z $__INC_EXPECT_CORE ] || return [ -z $__INC_EXPECT_CORE ] || return
__INC_EXPECT_CORE=1 __INC_EXPECT_CORE=1
source util
# reserved for our uses # reserved for our uses
exec 99<>/dev/null exec 99<>/dev/null
@ -86,8 +88,7 @@ _expect--output()
} }
} 99<&0 } 99<&0
# long version in case pipefail isn't supported on the system aok "${PIPESTATUS[@]}"
[ "${PIPESTATUS[0]}" -eq 0 -a "${PIPESTATUS[1]}" -eq 0 ]
} }
__expect--output-clause() __expect--output-clause()