git/list[1] front-page[2] threads[3] people[4] search[5] about
 

[PATCH 4/4] t7004: use "test-tool ref-store" for reflog inspection

From
Han-Wen Nienhuys via GitGitGadget <gitgitgadget@gmail.com>
Date
Dec 22, 2021, 10:59 UTC
Message-ID
<5d693273e5852ae9b302cb79e8dd986b6ffa10da.1640170784.git.gitgitgadget@gmail.com>
In-Reply-To
<pull.1168.git.git.1640170784.gitgitgadget@gmail.com>
From: Han-Wen Nienhuys <hanwen@google.com>
This makes the test work with reftable.
Signed-off-by: Han-Wen Nienhuys <hanwen@google.com>
---
 t/t7004-tag.sh | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/t/t7004-tag.sh b/t/t7004-tag.sh
index 301d1190482..bc8a221b2c7 100755
--- a/t/t7004-tag.sh
+++ b/t/t7004-tag.sh
@@ -97,7 +97,7 @@ test_expect_success 'creating a tag with --create-reflog should create reflog' '
 	test_when_finished "git tag -d tag_with_reflog1" &&
 	git tag --create-reflog tag_with_reflog1 &&
 	git reflog exists refs/tags/tag_with_reflog1 &&
-	sed -e "s/^.*	//" .git/logs/refs/tags/tag_with_reflog1 >actual &&
+	test-tool ref-store main for-each-reflog-ent refs/tags/tag_with_reflog1 | sed -e "s/^.*	//" >actual &&
 	test_cmp expected actual
 '
 
@@ -108,7 +108,7 @@ test_expect_success 'annotated tag with --create-reflog has correct message' '
 	test_when_finished "git tag -d tag_with_reflog2" &&
 	git tag -m "annotated tag" --create-reflog tag_with_reflog2 &&
 	git reflog exists refs/tags/tag_with_reflog2 &&
-	sed -e "s/^.*	//" .git/logs/refs/tags/tag_with_reflog2 >actual &&
+	test-tool ref-store main for-each-reflog-ent refs/tags/tag_with_reflog2 | sed -e "s/^.*	//" >actual &&
 	test_cmp expected actual
 '
 
-- 
gitgitgadget
Previous: Junio C HamanoNext: Junio C Hamano
Message 8 of 9 in “Reftable test fixes 20211221”
  1. 0/4 Reftable test fixes 20211221Han-Wen Nienhuys via GitGitGadget, Dec 22, 2021
  2. 1/4 t5540: require REFFILESHan-Wen Nienhuys via GitGitGadget, Dec 22, 2021
  3. Bagas SanjayaDec 24, 2021
  4. Han-Wen NienhuysJan 10, 2022
  5. 2/4 t5550: require REFFILESHan-Wen Nienhuys via GitGitGadget, Dec 22, 2021
  6. 3/4 t7004: create separate tags for different testsHan-Wen Nienhuys via GitGitGadget, Dec 22, 2021
  7. Junio C HamanoDec 22, 2021
  8. 4/4 t7004: use "test-tool ref-store" for reflog inspectionHan-Wen Nienhuys via GitGitGadget, Dec 22, 2021
  9. Junio C HamanoDec 22, 2021

Read the whole thread, see it on lore, or plain text.

$ cat FOOTERMessages come from the public archive at lore.kernel.org/git, fetched every hour. The front page is chosen and written each morning by an AI editor and can be wrong; the threads themselves are the record. About and API. For agents: an MCP server at https://gitlist.dev/mcp, and any thread, story or person page as Markdown by adding .md to its URL (or sending Accept: text/markdown). Details in /llms.txt.