]> git.ipfire.org Git - thirdparty/git.git/blobdiff - t/t6000-rev-list-misc.sh
Merge branch 'dl/reset-doc-no-wrt-abbrev'
[thirdparty/git.git] / t / t6000-rev-list-misc.sh
index fb4d295aa0f17c6aa967555ed92b4bc02884a9b3..05079997291fe295aacc80be1f26fd7002f0a898 100755 (executable)
@@ -90,11 +90,18 @@ test_expect_success 'rev-list can show index objects' '
        9200b628cf9dc883a85a7abc8d6e6730baee589c two
        EOF
        echo only-in-index >only-in-index &&
+       test_when_finished "git reset --hard" &&
        git add only-in-index &&
        git rev-list --objects --indexed-objects >actual &&
        test_cmp expect actual
 '
 
+test_expect_success 'rev-list can negate index objects' '
+       git rev-parse HEAD >expect &&
+       git rev-list -1 --objects HEAD --not --indexed-objects >actual &&
+       test_cmp expect actual
+'
+
 test_expect_success '--bisect and --first-parent can not be combined' '
        test_must_fail git rev-list --bisect --first-parent HEAD
 '