unit-tests: do not mistake `.pdb` files for being executable
[git.git] / t / t1418-reflog-exists.sh
blob2268bca3c11ac8e2d73e3a399b8debc44fc712cb
1 #!/bin/sh
3 test_description='Test reflog display routines'
4 GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME=main
5 export GIT_TEST_DEFAULT_INITIAL_BRANCH_NAME
7 TEST_PASSES_SANITIZE_LEAK=true
8 . ./test-lib.sh
10 test_expect_success 'setup' '
11 test_commit A
14 test_expect_success 'usage' '
15 test_expect_code 129 git reflog exists &&
16 test_expect_code 129 git reflog exists -h
19 test_expect_success 'usage: unknown option' '
20 test_expect_code 129 git reflog exists --unknown-option
23 test_expect_success 'reflog exists works' '
24 git reflog exists refs/heads/main &&
25 test_must_fail git reflog exists refs/heads/nonexistent
28 test_expect_success 'reflog exists works with a "--" delimiter' '
29 git reflog exists -- refs/heads/main &&
30 test_must_fail git reflog exists -- refs/heads/nonexistent
33 test_expect_success 'reflog exists works with a "--end-of-options" delimiter' '
34 git reflog exists --end-of-options refs/heads/main &&
35 test_must_fail git reflog exists --end-of-options refs/heads/nonexistent
38 test_done