From ac72177dfa12ae59b4b8a8b7bfe5eaf5bafd30b9 Mon Sep 17 00:00:00 2001 From: "Dmitriy.Panov" Date: Fri, 8 Jan 2021 11:33:54 +0300 Subject: [PATCH] option to ignore empty test suite GitOrigin-RevId: ced13750aab3759f67921bd9f9ec991429c5f58c --- .../testFramework/core/src/com/intellij/TestCaseLoader.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/platform/testFramework/core/src/com/intellij/TestCaseLoader.java b/platform/testFramework/core/src/com/intellij/TestCaseLoader.java index 80aa7b8f9b8c..8f72c0747434 100644 --- a/platform/testFramework/core/src/com/intellij/TestCaseLoader.java +++ b/platform/testFramework/core/src/com/intellij/TestCaseLoader.java @@ -369,7 +369,7 @@ public class TestCaseLoader { String message = "Number of test classes found: " + getClassesCount() + " time to load: " + (after - before) / 1000 + "s."; System.out.println(message); - if (!RUN_ONLY_AFFECTED_TESTS && getClassesCount() == 0) { + if (!RUN_ONLY_AFFECTED_TESTS && getClassesCount() == 0 && !"true".equals(System.getProperty("idea.tests.ignoreEmptySuite"))) { // Specially formatted error message will fail the build // See https://www.jetbrains.com/help/teamcity/build-script-interaction-with-teamcity.html#BuildScriptInteractionwithTeamCity-ReportingMessagesForBuildLog System.out.println("##teamcity[message text='Expected some tests to be executed, but no test classes were found.' status='ERROR']");