]> git.ipfire.org Git - thirdparty/git.git/blobdiff - t/t1506-rev-parse-diagnosis.sh
Merge branch 'js/update-index-ignore-removal-for-skip-worktree'
[thirdparty/git.git] / t / t1506-rev-parse-diagnosis.sh
index 21a9c8ffb2bbe4621d5866e5f0264676d7f1d77b..624d0a588fe6dda03b929cd4239f62e765efa04a 100755 (executable)
@@ -214,4 +214,12 @@ test_expect_success 'arg before dashdash must be a revision (ambiguous)' '
        test_cmp expect actual
 '
 
+test_expect_success 'reject Nth parent if N is too high' '
+       test_must_fail git rev-parse HEAD^100000000000000000000000000000000
+'
+
+test_expect_success 'reject Nth ancestor if N is too high' '
+       test_must_fail git rev-parse HEAD~100000000000000000000000000000000
+'
+
 test_done