[v2,2/8] fsmonitor: do not output to stderr for tests
diff mbox series

Message ID dd492091e329fbc75571dd5d64bfdfd845daec80.1575907804.git.gitgitgadget@gmail.com
State New
Headers show
Series
  • Improve testability with GIT_TEST_FSMONITOR
Related show

Commit Message

Matthew Rogers via GitGitGadget Dec. 9, 2019, 4:09 p.m. UTC
From: Derrick Stolee <dstolee@microsoft.com>

The fsmonitor feature allows an external tool such as watchman to
monitor the working directory. The direct test
t7619-status-fsmonitor.sh provides some coverage, but it would be
better to run the entire test suite with watchman enabled. This
would provide more confidence that the feature is working as
intended.

The test t0003-attributes.sh and others would fail when
GIT_TEST_FSMONITOR is pointing at t/t7519/fsmonitor-watchman because
it sends a message over stderr when registering the repo with
watchman for the first time. Remove this stderr message for the
test script to avoid this noise.

Signed-off-by: Derrick Stolee <dstolee@microsoft.com>
---
 t/t7519/fsmonitor-watchman | 1 -
 1 file changed, 1 deletion(-)

Patch
diff mbox series

diff --git a/t/t7519/fsmonitor-watchman b/t/t7519/fsmonitor-watchman
index d8e7a1e5ba..06312876aa 100755
--- a/t/t7519/fsmonitor-watchman
+++ b/t/t7519/fsmonitor-watchman
@@ -94,7 +94,6 @@  sub launch_watchman {
 	my $o = $json_pkg->new->utf8->decode($response);
 
 	if ($retry > 0 and $o->{error} and $o->{error} =~ m/unable to resolve root .* directory (.*) is not watched/) {
-		print STDERR "Adding '$git_work_tree' to watchman's watch list.\n";
 		$retry--;
 		qx/watchman watch "$git_work_tree"/;
 		die "Failed to make watchman watch '$git_work_tree'.\n" .