From f3bd35fa0dd6fcc8aaab1f9281d98cee5add2e4f Mon Sep 17 00:00:00 2001 From: "Stephen P. Smith" Date: Wed, 5 Sep 2018 17:53:29 -0700 Subject: wt-status.c: set the committable flag in the collect phase In an update to fix a bug with "commit --dry-run" it was found that the committable flag was broken. The update was, at the time, accepted as it was better than the previous version. [1] Since the setting of the committable flag had been done in wt_longstatus_print_updated, move it to wt_status_collect_updated_cb. Set the committable flag in wt_status_collect_changes_initial to keep from introducing a rebase regression. Instead of setting the committable flag in show_merge_in_progress, in wt_status_cllect check for a merge that has not been committed. If present then set the committable flag. Change the tests to expect success since updates to the wt-status broken code section is being fixed. [1] https://public-inbox.org/git/xmqqr3gcj9i5.fsf@gitster.mtv.corp.google.com/ Signed-off-by: Stephen P. Smith Signed-off-by: Junio C Hamano --- t/t7501-commit.sh | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 't/t7501-commit.sh') diff --git a/t/t7501-commit.sh b/t/t7501-commit.sh index cf2a4c5392..e18c0b4a6a 100755 --- a/t/t7501-commit.sh +++ b/t/t7501-commit.sh @@ -99,12 +99,12 @@ test_expect_success '--dry-run with stuff to commit returns ok' ' git commit -m next -a --dry-run ' -test_expect_failure '--short with stuff to commit returns ok' ' +test_expect_success '--short with stuff to commit returns ok' ' echo bongo bongo bongo >>file && git commit -m next -a --short ' -test_expect_failure '--porcelain with stuff to commit returns ok' ' +test_expect_success '--porcelain with stuff to commit returns ok' ' echo bongo bongo bongo >>file && git commit -m next -a --porcelain ' @@ -682,7 +682,7 @@ test_expect_success '--dry-run with conflicts fixed from a merge' ' git commit -m "conflicts fixed from merge." ' -test_expect_failure '--dry-run --short' ' +test_expect_success '--dry-run --short' ' >test-file && git add test-file && git commit --dry-run --short -- cgit v1.3