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

[PATCH] perf/fsmonitor: use test_must_be_empty helper

From
Nipunn Koorapati via GitGitGadget <gitgitgadget@gmail.com>
Date
Nov 25, 2020, 22:11 UTC
Message-ID
<pull.799.git.1606342297403.gitgitgadget@gmail.com>
From: Nipunn Koorapati <nipunn@dropbox.com>

Simplify test and make error messages more clear here. Per feedback from Junio in 33226af42b (t/perf/fsmonitor: improve error message if typoing hook name, 2020-10-26)

Signed-off-by: Nipunn Koorapati <nipunn@dropbox.com>
---
    perf/fsmonitor: use test_must_be_empty helper
    
    Simplify perf/fsmonitor test and make error messages more clear.
Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-799%2Fnipunn1313%2Fnk%2Ffsmonitor-test-cleanup-v1
Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-799/nipunn1313/nk/fsmonitor-test-cleanup-v1
Pull-Request: https://github.com/gitgitgadget/git/pull/799
 t/perf/p7519-fsmonitor.sh | 3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/t/perf/p7519-fsmonitor.sh b/t/perf/p7519-fsmonitor.sh
index 163a13bea3..9b43342806 100755
--- a/t/perf/p7519-fsmonitor.sh
+++ b/t/perf/p7519-fsmonitor.sh
@@ -129,8 +129,7 @@ setup_for_fsmonitor() {
 
 	git config core.fsmonitor "$INTEGRATION_SCRIPT" &&
 	git update-index --fsmonitor 2>error &&
-	cat error &&
-	[ ! -s error ] # ensure no silent error
+	test_must_be_empty error  # ensure no silent error
 }
 
 test_perf_w_drop_caches () {

base-commit: b291b0a628020eedb10b6236d87fe25d295cea81
-- 
gitgitgadget
Next: Derrick Stolee
Message 1 of 2 in “perf/fsmonitor: use test_must_be_empty helper”
  1. perf/fsmonitor: use test_must_be_empty helperNipunn Koorapati via GitGitGadget, Nov 25, 2020
  2. Derrick StoleeNov 30, 2020

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.