Merge branch 'cc/maint-bisect-paths' into maint
* cc/maint-bisect-paths: bisect: error out when passing bad path parameters
This commit is contained in:
commit
ce5044df2a
6
bisect.c
6
bisect.c
@ -986,6 +986,12 @@ int bisect_next_all(const char *prefix)
|
|||||||
exit(1);
|
exit(1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (!all) {
|
||||||
|
fprintf(stderr, "No testable commit found.\n"
|
||||||
|
"Maybe you started with bad path parameters?\n");
|
||||||
|
exit(4);
|
||||||
|
}
|
||||||
|
|
||||||
bisect_rev = revs.commits->item->object.sha1;
|
bisect_rev = revs.commits->item->object.sha1;
|
||||||
memcpy(bisect_rev_hex, sha1_to_hex(bisect_rev), 41);
|
memcpy(bisect_rev_hex, sha1_to_hex(bisect_rev), 41);
|
||||||
|
|
||||||
|
@ -567,6 +567,11 @@ test_expect_success 'skipping away from skipped commit' '
|
|||||||
test "$para3" = "$PARA_HASH3"
|
test "$para3" = "$PARA_HASH3"
|
||||||
'
|
'
|
||||||
|
|
||||||
|
test_expect_success 'erroring out when using bad path parameters' '
|
||||||
|
test_must_fail git bisect start $PARA_HASH7 $HASH1 -- foobar 2> error.txt &&
|
||||||
|
grep "bad path parameters" error.txt
|
||||||
|
'
|
||||||
|
|
||||||
#
|
#
|
||||||
#
|
#
|
||||||
test_done
|
test_done
|
||||||
|
Loading…
Reference in New Issue
Block a user