{"thread":{"id":"49158","subject":"[PATCH] t2024: mark test using \"checkout -p\" with PERL prerequisite","startedAt":"2018-08-18T04:50:23Z","lastAt":"2018-08-18T07:01:53Z","messageCount":2,"participants":["CB Bailey","Ævar Arnfjörð Bjarmason"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"355961","messageId":"20180818044310.14446-1-cb@hashpling.org","threadId":"49158","inReplyTo":null,"subject":"[PATCH] t2024: mark test using \"checkout -p\" with PERL prerequisite","fromName":"CB Bailey","fromEmail":"cb@hashpling.org","sentAt":"2018-08-18T04:43:10Z","receivedAt":"2018-08-18T04:50:23Z","isPatch":true,"sender":{"key":"cb@hashpling.org","avatar":null},"body":"checkout with the -p switch uses the \"add interactive\" framework which\nis written in Perl. Add a PERL prerequisite to skip this test when built\nwith NO_PERL.\n\nSigned-off-by: CB Bailey <cb@hashpling.org>\n---\n t/t2024-checkout-dwim.sh | 2 +-\n 1 file changed, 1 insertion(+), 1 deletion(-)\n\ndiff --git a/t/t2024-checkout-dwim.sh b/t/t2024-checkout-dwim.sh\nindex f79dfbbdd6..0e512c3066 100755\n--- a/t/t2024-checkout-dwim.sh\n+++ b/t/t2024-checkout-dwim.sh\n@@ -75,7 +75,7 @@ test_expect_success 'checkout of branch from multiple remotes fails #1' '\n \ttest_branch master\n '\n \n-test_expect_success 'checkout of branch from multiple remotes fails with advice' '\n+test_expect_success PERL 'checkout of branch from multiple remotes fails with advice' '\n \tgit checkout -B master &&\n \ttest_might_fail git branch -D foo &&\n \ttest_must_fail git checkout foo 2>stderr &&\n-- \n2.14.3 (Apple Git-98)\n\n"},{"id":"355968","messageId":"20180818070147.14026-1-avarab@gmail.com","threadId":"49158","inReplyTo":"20180818044310.14446-1-cb@hashpling.org","subject":"[PATCH] t2024: mark test using \"checkout -p\" with PERL prerequisite","fromName":"Ævar Arnfjörð Bjarmason","fromEmail":"avarab@gmail.com","sentAt":"2018-08-18T07:01:47Z","receivedAt":"2018-08-18T07:01:53Z","isPatch":true,"sender":{"key":"avarab@gmail.com","avatar":"https://avatars.githubusercontent.com/u/45301?v=4"},"body":"Checkout with the -p switch uses the \"add interactive\" framework which\nis written in Perl.\n\nOne test added in 8d7b558bae (\"checkout & worktree: introduce\ncheckout.defaultRemote\", 2018-06-05) didn't declare the PERL\nprerequisite, breaking the test when built with NO_PERL.\n\nReported-by: CB Bailey <cb@hashpling.org>\nSigned-off-by: CB Bailey <cb@hashpling.org>\nSigned-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>\n---\n\nOn Sat, Aug 18, 2018 at 6:43 AM, CB Bailey <cb@hashpling.org> wrote:\n> checkout with the -p switch uses the \"add interactive\" framework which\n> is written in Perl. Add a PERL prerequisite to skip this test when built\n> with NO_PERL.\n\nThanks, and sorry about my buggy code. I didn't consider the\ninteraction between -p and NO_PERL.\n\nYour patch works, but I think just splitting the test up is better, so\nwe're not skipping things unrelated to \"checkout -p\" under NO_PERL.\n\nI added your SOB since I stole significant parts of your commit\nmessage.\n\nJunio: We'd want one patch or the other before 2.19 so that release\ndoesn't break tests under NO_PERL.\n\n t/t2024-checkout-dwim.sh | 9 +++++++--\n 1 file changed, 7 insertions(+), 2 deletions(-)\n\ndiff --git a/t/t2024-checkout-dwim.sh b/t/t2024-checkout-dwim.sh\nindex f79dfbbdd6..69b6774d10 100755\n--- a/t/t2024-checkout-dwim.sh\n+++ b/t/t2024-checkout-dwim.sh\n@@ -86,8 +86,13 @@ test_expect_success 'checkout of branch from multiple remotes fails with advice'\n \t\tcheckout foo 2>stderr &&\n \ttest_branch master &&\n \tstatus_uno_is_clean &&\n-\ttest_i18ngrep ! \"^hint: \" stderr &&\n-\t# Make sure the likes of checkout -p do not print this hint\n+\ttest_i18ngrep ! \"^hint: \" stderr\n+'\n+\n+test_expect_success PERL 'checkout -p with multiple remotes does not print advice' '\n+\tgit checkout -B master &&\n+\ttest_might_fail git branch -D foo &&\n+\n \tgit checkout -p foo 2>stderr &&\n \ttest_i18ngrep ! \"^hint: \" stderr &&\n \tstatus_uno_is_clean\n-- \n2.18.0.865.gffc8e1a3cd6\n\n"}]}