Thread (63 messages) 63 messages, 7 authors, 2024-10-07

Re: [PATCH v5 2/2] t3404: employing test_line_count() to replace test

From: Usman Akinyemi <hidden>
Date: 2024-10-07 11:11:09

On Mon, Oct 7, 2024 at 10:54 AM Patrick Steinhardt [off-list ref] wrote:
On Mon, Oct 07, 2024 at 10:51:48AM +0000, Usman Akinyemi via GitGitGadget wrote:
quoted
From: Usman Akinyemi <redacted>
diff --git a/t/t3404-rebase-interactive.sh b/t/t3404-rebase-interactive.sh
index 96a65783c47..1073eb88fa2 100755
--- a/t/t3404-rebase-interactive.sh
+++ b/t/t3404-rebase-interactive.sh
@@ -281,7 +281,8 @@ test_expect_success 'stop on conflicting pick' '
      test_cmp expect2 file1 &&
      test "$(git diff --name-status |
              sed -n -e "/^U/s/^U[^a-z]*//p")" = file1 &&
-     test 4 = $(grep -v "^#" < .git/rebase-merge/done | wc -l) &&
+     grep -v "^#" < .git/rebase-merge/done >actual &&
+     test_line_count = 4 actual &&
      test 0 = $(grep -c "^[^#]" < .git/rebase-merge/git-rebase-todo)
 '
There's still the space between `<` and `.git/rebase-merge/git-rebase-todo`.
But overall this version looks good enough to me, so I don't think this
requires a reroll. Thanks!

Patrick
Thanks for the review. I think it is better to fix it now. I already
did. Thank you.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help