From 2fd69218061f8a55ca6524b58b7cc12180be6f6a Mon Sep 17 00:00:00 2001 From: Roman Artemev Date: Tue, 26 May 2020 16:15:06 +0300 Subject: [PATCH] [JS TESTS] Emulate failing of non-run tests --- .../test/org/jetbrains/kotlin/js/test/BasicBoxTest.kt | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/js/js.tests/test/org/jetbrains/kotlin/js/test/BasicBoxTest.kt b/js/js.tests/test/org/jetbrains/kotlin/js/test/BasicBoxTest.kt index 4c02e355dfe..c4761978614 100644 --- a/js/js.tests/test/org/jetbrains/kotlin/js/test/BasicBoxTest.kt +++ b/js/js.tests/test/org/jetbrains/kotlin/js/test/BasicBoxTest.kt @@ -254,6 +254,15 @@ abstract class BasicBoxTest( if (runIrPir && !skipDceDriven) { runGeneratedCode(pirAllJsFiles, testModuleName, testPackage, testFunction, expectedResult, withModuleSystem) } + } else { + val ignored = InTextDirectivesUtils.isIgnoredTarget( + targetBackend, file, + InTextDirectivesUtils.IGNORE_BACKEND_DIRECTIVE_PREFIX + ) + + if (ignored) { + throw AssertionError("Ignored test hasn't been ran. Emulate its failing") + } } performAdditionalChecks(generatedJsFiles.map { it.first }, outputPrefixFile, outputPostfixFile)