stash drops the stash even if creating the branch fails because it already exists
[git/dscho.git] / t / t3020-ls-files-error-unmatch.sh
bloba7d8187169a36f708bd7dc39d97604dd9cc21565
1 #!/bin/sh
3 # Copyright (c) 2006 Carl D. Worth
6 test_description='git ls-files test for --error-unmatch option
8 This test runs git ls-files --error-unmatch to ensure it correctly
9 returns an error when a non-existent path is provided on the command
10 line.
12 . ./test-lib.sh
14 test_expect_success 'setup' '
15 touch foo bar &&
16 git update-index --add foo bar &&
17 git commit -m "add foo bar"
20 test_expect_success \
21 'git ls-files --error-unmatch should fail with unmatched path.' \
22 'test_must_fail git ls-files --error-unmatch foo bar-does-not-match'
24 test_expect_success \
25 'git ls-files --error-unmatch should succeed eith matched paths.' \
26 'git ls-files --error-unmatch foo bar'
28 test_done