Skip to content

Commit

Permalink
tests: shell negation portability fix
Browse files Browse the repository at this point in the history
Commit 969c8775 introduced a test which uses the non-portable construct:

  command1 && ! command2 | command3

which must be

  command1 && ! (command2 | command3)

to work on bsd shells (this is another example of bbf0812, which fixed
several similar cases).

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
  • Loading branch information
peff authored and gitster committed Oct 17, 2008
1 parent 8ed0a74 commit 7213080
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion t/t4128-apply-root.sh
Expand Up @@ -72,7 +72,7 @@ test_expect_success 'apply --directory (delete file)' '
echo content >some/sub/dir/delfile &&
git add some/sub/dir/delfile &&
git apply --directory=some/sub/dir/ --index patch &&
! git ls-files | grep delfile
! (git ls-files | grep delfile)
'

cat > patch << 'EOF'
Expand Down

0 comments on commit 7213080

Please sign in to comment.