{"thread":{"id":"2071","subject":"[PATCH] Use git-update-ref and git-symbolic-ref in tests","startedAt":"2005-10-11T14:02:39Z","lastAt":"2005-10-11T19:57:28Z","messageCount":2,"participants":["Johannes Schindelin","Junio C Hamano"],"isPatch":true,"patchVersion":1,"patchTotal":null},"messages":[{"id":"9958","messageId":"Pine.LNX.4.63.0510111601460.27536@wbgn013.biozentrum.uni-wuerzburg.de","threadId":"2071","inReplyTo":null,"subject":"[PATCH] Use git-update-ref and git-symbolic-ref in tests","fromName":"Johannes Schindelin","fromEmail":"johannes.schindelin@gmx.de","sentAt":"2005-10-11T14:02:39Z","receivedAt":"2005-10-11T14:02:39Z","isPatch":true,"sender":{"key":"johannes.schindelin@gmx.de","avatar":"https://avatars.githubusercontent.com/u/127790?v=4"},"body":"This makes all tests pass on cygwin.\n\nSigned-off-by: Johannes Schindelin <Johannes.Schindelin@gmx.de>\n\n---\n\n t/t5000-tar-tree.sh             |    6 +++---\n t/t6001-rev-list-merge-order.sh |    2 +-\n t/t6002-rev-list-bisect.sh      |    2 +-\n t/t6003-rev-list-topo-order.sh  |    2 +-\n 4 files changed, 6 insertions(+), 6 deletions(-)\n\napplies-to: c6ce0dfdf028e37ae907628a56895afc14d6d7a0\nf86f79547964a7e9d23535c4971d757117800aa2\ndiff --git a/t/t5000-tar-tree.sh b/t/t5000-tar-tree.sh\nindex 5dffb8e..4db1bb1 100755\n--- a/t/t5000-tar-tree.sh\n+++ b/t/t5000-tar-tree.sh\n@@ -41,8 +41,8 @@ test_expect_success \\\n      find a -type l | xargs git-update-index --add &&\n      treeid=`git-write-tree` &&\n      echo $treeid >treeid &&\n-     TZ=GMT GIT_COMMITTER_DATE=\"2005-05-27 22:00:00\" \\\n-     git-commit-tree $treeid </dev/null >.git/HEAD'\n+     git-update-ref HEAD $(TZ=GMT GIT_COMMITTER_DATE=\"2005-05-27 22:00:00\" \\\n+     git-commit-tree $treeid </dev/null)'\n \n test_expect_success \\\n     'git-tar-tree' \\\n@@ -59,7 +59,7 @@ test_expect_success \\\n test_expect_success \\\n     'git-get-tar-commit-id' \\\n     'git-get-tar-commit-id <b.tar >b.commitid &&\n-     diff .git/HEAD b.commitid'\n+     diff .git/$(git-symbolic-ref HEAD) b.commitid'\n \n test_expect_success \\\n     'extract tar archive' \\\ndiff --git a/t/t6001-rev-list-merge-order.sh b/t/t6001-rev-list-merge-order.sh\nindex 0101242..8ec9ebb 100755\n--- a/t/t6001-rev-list-merge-order.sh\n+++ b/t/t6001-rev-list-merge-order.sh\n@@ -108,7 +108,7 @@ save_tag h2 unique_commit g4 tree -p g2\n save_tag g3 unique_commit g5 tree -p g2\n save_tag g4 unique_commit g6 tree -p g3 -p h2\n \n-tag l5 > .git/HEAD\n+git-update-ref HEAD $(tag l5)\n \n test_expect_success 'rev-list has correct number of entries' 'git-rev-list HEAD | wc -l | tr -s \" \"' <<EOF\n 19\ndiff --git a/t/t6002-rev-list-bisect.sh b/t/t6002-rev-list-bisect.sh\nindex 42fcbc6..693de9b 100755\n--- a/t/t6002-rev-list-bisect.sh\n+++ b/t/t6002-rev-list-bisect.sh\n@@ -58,7 +58,7 @@ on_committer_date \"1971-08-16 00:00:15\" \n on_committer_date \"1971-08-16 00:00:16\" save_tag l3 unique_commit l3 tree -p a4\n on_committer_date \"1971-08-16 00:00:17\" save_tag l4 unique_commit l4 tree -p l3\n on_committer_date \"1971-08-16 00:00:18\" save_tag l5 unique_commit l5 tree -p l4\n-tag l5 > .git/HEAD\n+git-update-ref HEAD $(tag l5)\n \n \n #     E\ndiff --git a/t/t6003-rev-list-topo-order.sh b/t/t6003-rev-list-topo-order.sh\nindex 88d14ee..3c4c44c 100755\n--- a/t/t6003-rev-list-topo-order.sh\n+++ b/t/t6003-rev-list-topo-order.sh\n@@ -77,7 +77,7 @@ save_tag h2 unique_commit g4 tree -p g2\n save_tag g3 unique_commit g5 tree -p g2\n save_tag g4 unique_commit g6 tree -p g3 -p h2\n \n-tag l5 > .git/HEAD\n+git-update-ref HEAD $(tag l5)\n \n test_expect_success 'rev-list has correct number of entries' 'git-rev-list HEAD | wc -l | tr -s \" \"' <<EOF\n 19\n---\n0.99.8.GIT\n"},{"id":"9975","messageId":"7v1x2ru8rb.fsf@assigned-by-dhcp.cox.net","threadId":"2071","inReplyTo":"Pine.LNX.4.63.0510111601460.27536@wbgn013.biozentrum.uni-wuerzburg.de","subject":"Re: [PATCH] Use git-update-ref and git-symbolic-ref in tests","fromName":"Junio C Hamano","fromEmail":"junkio@cox.net","sentAt":"2005-10-11T19:57:28Z","receivedAt":"2005-10-11T19:57:28Z","isPatch":true,"sender":{"key":"gitster@pobox.com","avatar":"https://avatars.githubusercontent.com/u/54884?v=4"},"body":"Johannes Schindelin <Johannes.Schindelin@gmx.de> writes:\n\n> This makes all tests pass on cygwin.\n\nThanks.  Forgot about these tests.\n"}]}