diff --git a/docs/start/go.mdx b/docs/start/go.mdx index 3a0956819d506c..f47399d7537780 100644 --- a/docs/start/go.mdx +++ b/docs/start/go.mdx @@ -427,7 +427,6 @@ INFO: Build completed successfully, 1 total action //fortune:fortune_test PASSED in 0.3s Executed 0 out of 1 test: 1 test passes. -There were tests whose specified size is too big. Use the --test_verbose_timeout_warnings command line option to see which ones these are. ``` You can use the `...` wildcard to run all tests. Bazel will also build targets diff --git a/site/en/start/go.md b/site/en/start/go.md index 1f04c7475eac4b..85b98125541014 100644 --- a/site/en/start/go.md +++ b/site/en/start/go.md @@ -431,7 +431,6 @@ INFO: Build completed successfully, 1 total action //fortune:fortune_test PASSED in 0.3s Executed 0 out of 1 test: 1 test passes. -There were tests whose specified size is too big. Use the --test_verbose_timeout_warnings command line option to see which ones these are. ``` You can use the `...` wildcard to run all tests. Bazel will also build targets diff --git a/src/main/java/com/google/devtools/build/lib/runtime/TerminalTestResultNotifier.java b/src/main/java/com/google/devtools/build/lib/runtime/TerminalTestResultNotifier.java index fb0d4682090b78..83f8729933809b 100644 --- a/src/main/java/com/google/devtools/build/lib/runtime/TerminalTestResultNotifier.java +++ b/src/main/java/com/google/devtools/build/lib/runtime/TerminalTestResultNotifier.java @@ -54,7 +54,6 @@ private static class TestResultStats { int failedLocallyCount; int noStatusCount; int numberOfExecutedTargets; - boolean wasUnreportedWrongSize; int totalTestCases; int totalFailedTestCases; @@ -189,10 +188,6 @@ public void notify(Set summaries, int numberOfExecutedTargets) { stats.failedLocallyCount++; } - if (summary.wasUnreportedWrongSize()) { - stats.wasUnreportedWrongSize = true; - } - stats.totalTestCases += summary.getTotalTestCases(); stats.totalUnknownTestCases += summary.getUnkownTestCases(); stats.totalFailedTestCases += summary.getFailedTestCases().size(); @@ -323,11 +318,5 @@ private void printStats(TestResultStats stats) { stats.noStatusCount, AnsiTerminalPrinter.Mode.DEFAULT)); } - - if (stats.wasUnreportedWrongSize) { - printer.print("There were tests whose specified size is too big. Use the " - + "--test_verbose_timeout_warnings command line option to see which " - + "ones these are.\n"); - } } } diff --git a/src/main/java/com/google/devtools/build/lib/runtime/TestResultAggregator.java b/src/main/java/com/google/devtools/build/lib/runtime/TestResultAggregator.java index 497479d40e0a84..ec4967c929aa2c 100644 --- a/src/main/java/com/google/devtools/build/lib/runtime/TestResultAggregator.java +++ b/src/main/java/com/google/devtools/build/lib/runtime/TestResultAggregator.java @@ -250,13 +250,12 @@ private void incrementalAnalyze(TestResult result) { .setRanRemotely(result.getData().getIsRemoteStrategy()); List warnings = new ArrayList<>(); - if (status == BlazeTestStatus.PASSED - && shouldEmitTestSizeWarningInSummary( - policy.testVerboseTimeoutWarnings, - warnings, - result.getData().getTestProcessTimesList(), - target)) { - summary.setWasUnreportedWrongSize(true); + if (status == BlazeTestStatus.PASSED) { + shouldEmitTestSizeWarningInSummary( + policy.testVerboseTimeoutWarnings, + warnings, + result.getData().getTestProcessTimesList(), + target); } summary diff --git a/src/main/java/com/google/devtools/build/lib/runtime/TestSummary.java b/src/main/java/com/google/devtools/build/lib/runtime/TestSummary.java index 80a1ffac8c55ab..cec89973ac1551 100644 --- a/src/main/java/com/google/devtools/build/lib/runtime/TestSummary.java +++ b/src/main/java/com/google/devtools/build/lib/runtime/TestSummary.java @@ -100,7 +100,6 @@ void mergeFrom(TestSummary existingSummary) { setActionRan(existingSummary.actionRan); setNumCached(existingSummary.numCached); setRanRemotely(existingSummary.ranRemotely); - setWasUnreportedWrongSize(existingSummary.wasUnreportedWrongSize); mergeSystemFailure(existingSummary.getSystemFailure()); } @@ -318,13 +317,6 @@ public Builder setRanRemotely(boolean ranRemotely) { return this; } - @CanIgnoreReturnValue - public Builder setWasUnreportedWrongSize(boolean wasUnreportedWrongSize) { - checkMutation(); - summary.wasUnreportedWrongSize = wasUnreportedWrongSize; - return this; - } - @CanIgnoreReturnValue public Builder mergeSystemFailure(@Nullable DetailedExitCode systemFailure) { checkMutation(); @@ -403,7 +395,6 @@ private void makeSummaryImmutable() { private int numLocalActionCached; private boolean actionRan; private boolean ranRemotely; - private boolean wasUnreportedWrongSize; private List failedTestCases = new ArrayList<>(); private final List passedTestCases = new ArrayList<>(); private final List skippedTestCases = new ArrayList<>(); @@ -502,10 +493,6 @@ public boolean ranRemotely() { return ranRemotely; } - public boolean wasUnreportedWrongSize() { - return wasUnreportedWrongSize; - } - public int getTotalTestCases() { return totalTestCases; } diff --git a/src/test/java/com/google/devtools/build/lib/runtime/TestSummaryTest.java b/src/test/java/com/google/devtools/build/lib/runtime/TestSummaryTest.java index 253d21f4f4f57d..9a60b71e12a1cf 100644 --- a/src/test/java/com/google/devtools/build/lib/runtime/TestSummaryTest.java +++ b/src/test/java/com/google/devtools/build/lib/runtime/TestSummaryTest.java @@ -89,8 +89,7 @@ private TestSummary.Builder getTemplateBuilder() { .setStatus(BlazeTestStatus.PASSED) .setNumCached(NOT_CACHED) .setActionRan(true) - .setRanRemotely(false) - .setWasUnreportedWrongSize(false); + .setRanRemotely(false); } private List getPathList(String... names) { @@ -705,7 +704,6 @@ private static TestSummary createTestSummary(ConfiguredTarget target, BlazeTestS .setNumCached(numCached) .setActionRan(true) .setRanRemotely(false) - .setWasUnreportedWrongSize(false) .addFailedTestCases(emptyList, FailedTestCasesStatus.FULL) .addTestTimes(SMALL_TIMING) .build();