{"thread":{"id":"38906","subject":"[PATCH] t1501: fix test with split index","startedAt":"2015-03-24T17:35:01Z","lastAt":"2015-03-24T19:21:40Z","messageCount":3,"participants":["Thomas Gummerer","Junio C Hamano"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"258430","messageId":"1427218501-4644-1-git-send-email-t.gummerer@gmail.com","threadId":"38906","inReplyTo":null,"subject":"[PATCH] t1501: fix test with split index","fromName":"Thomas Gummerer","fromEmail":"t.gummerer@gmail.com","sentAt":"2015-03-24T17:35:01Z","receivedAt":"2015-03-24T17:35:01Z","isPatch":true,"sender":{"key":"t.gummerer@gmail.com","avatar":"https://avatars.githubusercontent.com/u/191004?v=4"},"body":"t1501-worktree.sh does not copy the shared index in the \"relative\n$GIT_WORK_TREE and git subprocesses\" test, which makes the test fail\nwhen GIT_TEST_SPLIT_INDEX is set.  Copy the shared index as well in\norder to fix this.\n\nSigned-off-by: Thomas Gummerer <t.gummerer@gmail.com>\n---\n\nThis applies on top of nd/multiple-work-trees.  Sorry for not catching it\nearlier, but I haven't tried to run the test-suite for the next branch\nthen, where this appears.\n\n t/t1501-worktree.sh | 1 +\n 1 file changed, 1 insertion(+)\n\ndiff --git a/t/t1501-worktree.sh b/t/t1501-worktree.sh\nindex 4df7a2f..ce5c654 100755\n--- a/t/t1501-worktree.sh\n+++ b/t/t1501-worktree.sh\n@@ -350,6 +350,7 @@ test_expect_success 'Multi-worktree setup' '\n \tmkdir work &&\n \tmkdir -p repo.git/repos/foo &&\n \tcp repo.git/HEAD repo.git/index repo.git/repos/foo &&\n+\t( cp repo.git/sharedindex.* repo.git/repos/foo 2>/dev/null || : ) &&\n \tsane_unset GIT_DIR GIT_CONFIG GIT_WORK_TREE\n '\n \n-- \n2.1.0.264.g0463184.dirty\n"},{"id":"258437","messageId":"xmqqa8z26zwi.fsf@gitster.dls.corp.google.com","threadId":"38906","inReplyTo":"1427218501-4644-1-git-send-email-t.gummerer@gmail.com","subject":"Re: [PATCH] t1501: fix test with split index","fromName":"Junio C Hamano","fromEmail":"gitster@pobox.com","sentAt":"2015-03-24T17:58:21Z","receivedAt":"2015-03-24T17:58:21Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Thomas Gummerer <t.gummerer@gmail.com> writes:\n\n> t1501-worktree.sh does not copy the shared index in the \"relative\n> $GIT_WORK_TREE and git subprocesses\" test, which makes the test fail\n> when GIT_TEST_SPLIT_INDEX is set.  Copy the shared index as well in\n> order to fix this.\n>\n> Signed-off-by: Thomas Gummerer <t.gummerer@gmail.com>\n> ---\n>\n> This applies on top of nd/multiple-work-trees.  Sorry for not catching it\n> earlier, but I haven't tried to run the test-suite for the next branch\n> then, where this appears.\n>\n>  t/t1501-worktree.sh | 1 +\n>  1 file changed, 1 insertion(+)\n>\n> diff --git a/t/t1501-worktree.sh b/t/t1501-worktree.sh\n> index 4df7a2f..ce5c654 100755\n> --- a/t/t1501-worktree.sh\n> +++ b/t/t1501-worktree.sh\n> @@ -350,6 +350,7 @@ test_expect_success 'Multi-worktree setup' '\n>  \tmkdir work &&\n>  \tmkdir -p repo.git/repos/foo &&\n>  \tcp repo.git/HEAD repo.git/index repo.git/repos/foo &&\n> +\t( cp repo.git/sharedindex.* repo.git/repos/foo 2>/dev/null || : ) &&\n\nIs this a good place to use \"test-might-fail\", e.g.\n\n\ttest_might_fail cp repo.git/sharedindex.* repo.git/repos/foo &&\n\nor something?\n\n>  \tsane_unset GIT_DIR GIT_CONFIG GIT_WORK_TREE\n>  '\n"},{"id":"258444","messageId":"1427224900-2206-1-git-send-email-t.gummerer@gmail.com","threadId":"38906","inReplyTo":"xmqqa8z26zwi.fsf@gitster.dls.corp.google.com","subject":"[PATCH v2] t1501: fix test with split index","fromName":"Thomas Gummerer","fromEmail":"t.gummerer@gmail.com","sentAt":"2015-03-24T19:21:40Z","receivedAt":"2015-03-24T19:21:40Z","isPatch":true,"sender":{"key":"t.gummerer@gmail.com","avatar":"https://avatars.githubusercontent.com/u/191004?v=4"},"body":"t1501-worktree.sh does not copy the shared index in the \"relative\n$GIT_WORK_TREE and git subprocesses\" test, which makes the test fail\nwhen GIT_TEST_SPLIT_INDEX is set.  Copy the shared index as well in\norder to fix this.\n\nHelped-by: Junio C Hamano <gitster@pobox.com>\nSigned-off-by: Thomas Gummerer <t.gummerer@gmail.com>\n---\n\n> Is this a good place to use \"test-might-fail\", e.g.\n>\n>        test_might_fail cp repo.git/sharedindex.* repo.git/repos/foo &&\n>\n> or something?\n\nYeah that makes sense, thanks.\n\n t/t1501-worktree.sh | 1 +\n 1 file changed, 1 insertion(+)\n\ndiff --git a/t/t1501-worktree.sh b/t/t1501-worktree.sh\nindex 4df7a2f..cc5b870 100755\n--- a/t/t1501-worktree.sh\n+++ b/t/t1501-worktree.sh\n@@ -350,6 +350,7 @@ test_expect_success 'Multi-worktree setup' '\n \tmkdir work &&\n \tmkdir -p repo.git/repos/foo &&\n \tcp repo.git/HEAD repo.git/index repo.git/repos/foo &&\n+\ttest_might_fail cp repo.git/sharedindex.* repo.git/repos/foo &&\n \tsane_unset GIT_DIR GIT_CONFIG GIT_WORK_TREE\n '\n \n-- \n2.1.0.264.g0463184.dirty\n"}]}