perf/fsmonitor: use test_must_be_empty helper
authorNipunn Koorapati <redacted>
Wed, 25 Nov 2020 22:11:37 +0000 (22:11 +0000)
committerJunio C Hamano <redacted>
Mon, 30 Nov 2020 21:51:43 +0000 (13:51 -0800)
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 <redacted>
Acked-by: Derrick Stolee <redacted>
Signed-off-by: Junio C Hamano <redacted>
t/perf/p7519-fsmonitor.sh

index 163a13bea36f59d716e0c06336ade0738941d241..9b43342806b9e0243ccb81a60931abdf36034337 100755 (executable)
@@ -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 () {
git clone https://git.99rst.org/PROJECT