From a6600cef474da9d54d9e2189aef2a4419a8ddf56 Mon Sep 17 00:00:00 2001 From: Dmitriy Novozhilov Date: Thu, 14 Jan 2021 10:33:54 +0300 Subject: [PATCH] [Test] Remove some outdated tests from LocalInspectionTestGenerated Those tests are referring to outdated language features which are meaningless for language version 1.5 --- .../conversionPerArgumentDisabled1.kt | 8 -------- .../conversionPerArgumentDisabled2.kt | 12 ----------- .../conversionPerArgumentDisabled3.kt | 8 -------- .../removeRedundantBackticks/underscore.kt | 8 -------- .../LocalInspectionTestGenerated.java | 20 ------------------- 5 files changed, 56 deletions(-) delete mode 100644 idea/testData/inspectionsLocal/redundantSamConstructor/conversionPerArgumentDisabled1.kt delete mode 100644 idea/testData/inspectionsLocal/redundantSamConstructor/conversionPerArgumentDisabled2.kt delete mode 100644 idea/testData/inspectionsLocal/redundantSamConstructor/conversionPerArgumentDisabled3.kt delete mode 100644 idea/testData/inspectionsLocal/removeRedundantBackticks/underscore.kt diff --git a/idea/testData/inspectionsLocal/redundantSamConstructor/conversionPerArgumentDisabled1.kt b/idea/testData/inspectionsLocal/redundantSamConstructor/conversionPerArgumentDisabled1.kt deleted file mode 100644 index de9ff4bbd7b..00000000000 --- a/idea/testData/inspectionsLocal/redundantSamConstructor/conversionPerArgumentDisabled1.kt +++ /dev/null @@ -1,8 +0,0 @@ -// COMPILER_ARGUMENTS: -XXLanguage:+NewInference -XXLanguage:+SamConversionForKotlinFunctions -XXLanguage:+FunctionalInterfaceConversion -XXLanguage:-SamConversionPerArgument -// PROBLEM: none - -fun test(r1: Runnable, r2: Runnable) {} - -fun usage(r1: Runnable) { - test(r1, Runnable {}) -} diff --git a/idea/testData/inspectionsLocal/redundantSamConstructor/conversionPerArgumentDisabled2.kt b/idea/testData/inspectionsLocal/redundantSamConstructor/conversionPerArgumentDisabled2.kt deleted file mode 100644 index 82ecff5437a..00000000000 --- a/idea/testData/inspectionsLocal/redundantSamConstructor/conversionPerArgumentDisabled2.kt +++ /dev/null @@ -1,12 +0,0 @@ -// COMPILER_ARGUMENTS: -XXLanguage:+NewInference -XXLanguage:+SamConversionForKotlinFunctions -XXLanguage:+FunctionalInterfaceConversion -XXLanguage:-SamConversionPerArgument -// PROBLEM: none - -fun interface KtRunnable { - fun run() -} - -fun test(r1: KtRunnable, r2: KtRunnable) {} - -fun usage(r1: KtRunnable) { - test(r1, KtRunnable {}) -} diff --git a/idea/testData/inspectionsLocal/redundantSamConstructor/conversionPerArgumentDisabled3.kt b/idea/testData/inspectionsLocal/redundantSamConstructor/conversionPerArgumentDisabled3.kt deleted file mode 100644 index 83b4b56f196..00000000000 --- a/idea/testData/inspectionsLocal/redundantSamConstructor/conversionPerArgumentDisabled3.kt +++ /dev/null @@ -1,8 +0,0 @@ -// COMPILER_ARGUMENTS: -XXLanguage:+NewInference -XXLanguage:+SamConversionForKotlinFunctions -XXLanguage:+FunctionalInterfaceConversion -XXLanguage:-SamConversionPerArgument -// PROBLEM: none - -fun test(r1: Runnable, r2: Runnable) {} - -fun usage() { - test(Runnable { return@Runnable }, Runnable {}) -} diff --git a/idea/testData/inspectionsLocal/removeRedundantBackticks/underscore.kt b/idea/testData/inspectionsLocal/removeRedundantBackticks/underscore.kt deleted file mode 100644 index 6e8ffeee49d..00000000000 --- a/idea/testData/inspectionsLocal/removeRedundantBackticks/underscore.kt +++ /dev/null @@ -1,8 +0,0 @@ -// PROBLEM: none - -fun test() { - try { - } catch (_: Throwable) { - `_`.printStackTrace() - } -} \ No newline at end of file diff --git a/idea/tests/org/jetbrains/kotlin/idea/inspections/LocalInspectionTestGenerated.java b/idea/tests/org/jetbrains/kotlin/idea/inspections/LocalInspectionTestGenerated.java index 0d671f91375..5815f98b6be 100644 --- a/idea/tests/org/jetbrains/kotlin/idea/inspections/LocalInspectionTestGenerated.java +++ b/idea/tests/org/jetbrains/kotlin/idea/inspections/LocalInspectionTestGenerated.java @@ -8739,21 +8739,6 @@ public class LocalInspectionTestGenerated extends AbstractLocalInspectionTest { KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("idea/testData/inspectionsLocal/redundantSamConstructor"), Pattern.compile("^([\\w\\-_]+)\\.(kt|kts)$"), null, true); } - @TestMetadata("conversionPerArgumentDisabled1.kt") - public void testConversionPerArgumentDisabled1() throws Exception { - runTest("idea/testData/inspectionsLocal/redundantSamConstructor/conversionPerArgumentDisabled1.kt"); - } - - @TestMetadata("conversionPerArgumentDisabled2.kt") - public void testConversionPerArgumentDisabled2() throws Exception { - runTest("idea/testData/inspectionsLocal/redundantSamConstructor/conversionPerArgumentDisabled2.kt"); - } - - @TestMetadata("conversionPerArgumentDisabled3.kt") - public void testConversionPerArgumentDisabled3() throws Exception { - runTest("idea/testData/inspectionsLocal/redundantSamConstructor/conversionPerArgumentDisabled3.kt"); - } - @TestMetadata("conversionPerArgumentEnabled1.kt") public void testConversionPerArgumentEnabled1() throws Exception { runTest("idea/testData/inspectionsLocal/redundantSamConstructor/conversionPerArgumentEnabled1.kt"); @@ -9656,11 +9641,6 @@ public class LocalInspectionTestGenerated extends AbstractLocalInspectionTest { runTest("idea/testData/inspectionsLocal/removeRedundantBackticks/property.kt"); } - @TestMetadata("underscore.kt") - public void testUnderscore() throws Exception { - runTest("idea/testData/inspectionsLocal/removeRedundantBackticks/underscore.kt"); - } - @TestMetadata("underscores.kt") public void testUnderscores() throws Exception { runTest("idea/testData/inspectionsLocal/removeRedundantBackticks/underscores.kt");