pw_unit_test/test_runner: Only debug log on success
Updates the pw_unit_test/test_runner.py and pw_cli/process.py to
ensure that a successful host unit test run does not produce extra
ninja output when using CMake by using debug logs instead of info
logs for successful runs.
Change-Id: I463550854cbc534b52ed2c29e3ea7e763939010f
Reviewed-on: https://pigweed-review.googlesource.com/c/pigweed/pigweed/+/126846
Reviewed-by: Taylor Cramer <cramertj@google.com>
Pigweed-Auto-Submit: Ewout van Bekkum <ewout@google.com>
Reviewed-by: Wyatt Hepler <hepler@google.com>
Commit-Queue: Auto-Submit <auto-submit@pigweed.google.com.iam.gserviceaccount.com>
diff --git a/pw_cli/py/pw_cli/process.py b/pw_cli/py/pw_cli/process.py
index d30ed94..e683db8 100644
--- a/pw_cli/py/pw_cli/process.py
+++ b/pw_cli/py/pw_cli/process.py
@@ -129,7 +129,7 @@
if process.returncode:
_LOG.error('%s exited with status %d', program, process.returncode)
else:
- _LOG.info('%s exited successfully', program)
+ _LOG.debug('%s exited successfully', program)
return CompletedProcess(process, output)
diff --git a/pw_unit_test/py/pw_unit_test/test_runner.py b/pw_unit_test/py/pw_unit_test/test_runner.py
index b5c660e..bc88f99 100644
--- a/pw_unit_test/py/pw_unit_test/test_runner.py
+++ b/pw_unit_test/py/pw_unit_test/test_runner.py
@@ -185,7 +185,7 @@
total = str(len(self._tests))
test_counter = f'Test {idx:{len(total)}}/{total}'
- _LOG.info('%s: [ RUN] %s', test_counter, test.name)
+ _LOG.debug('%s: [ RUN] %s', test_counter, test.name)
# Convert POSIX to native directory seperators as GN produces '/'
# but the Windows test runner needs '\\'.