Add a pair of tests for KT-11154
This commit is contained in:
@@ -0,0 +1,8 @@
|
|||||||
|
// "Typo: Change to..." "false"
|
||||||
|
// TOOL: com.intellij.spellchecker.inspections.SpellCheckingInspection
|
||||||
|
// ACTION: Add 'const' modifier
|
||||||
|
// ACTION: Convert property initializer to getter
|
||||||
|
// ACTION: To raw string literal
|
||||||
|
|
||||||
|
@Suppress("SpellCheckingInspection")
|
||||||
|
val str = "<caret>kjsghkjshtiurhuig"
|
||||||
@@ -0,0 +1,16 @@
|
|||||||
|
// "Suppress Warnings" "true"
|
||||||
|
// TOOL: com.intellij.spellchecker.inspections.SpellCheckingInspection
|
||||||
|
// ACTION: Add 'const' modifier
|
||||||
|
// ACTION: Typo: Change to...
|
||||||
|
// ACTION: Edit inspection profile setting
|
||||||
|
// ACTION: Fix all 'Typo' problems in file
|
||||||
|
// ACTION: Run inspection on ...
|
||||||
|
// ACTION: Disable inspection
|
||||||
|
// ACTION: Save 'kjsghkjshtiurhuig' to project-level dictionary
|
||||||
|
// ACTION: Show property type hints
|
||||||
|
// ACTION: Edit intention settings
|
||||||
|
// ACTION: Convert property initializer to getter
|
||||||
|
// ACTION: Inject language or reference
|
||||||
|
// ACTION: To raw string literal
|
||||||
|
|
||||||
|
val str = "<caret>kjsghkjshtiurhuig"
|
||||||
@@ -0,0 +1,17 @@
|
|||||||
|
// "Suppress Warnings" "true"
|
||||||
|
// TOOL: com.intellij.spellchecker.inspections.SpellCheckingInspection
|
||||||
|
// ACTION: Add 'const' modifier
|
||||||
|
// ACTION: Typo: Change to...
|
||||||
|
// ACTION: Edit inspection profile setting
|
||||||
|
// ACTION: Fix all 'Typo' problems in file
|
||||||
|
// ACTION: Run inspection on ...
|
||||||
|
// ACTION: Disable inspection
|
||||||
|
// ACTION: Save 'kjsghkjshtiurhuig' to project-level dictionary
|
||||||
|
// ACTION: Show property type hints
|
||||||
|
// ACTION: Edit intention settings
|
||||||
|
// ACTION: Convert property initializer to getter
|
||||||
|
// ACTION: Inject language or reference
|
||||||
|
// ACTION: To raw string literal
|
||||||
|
|
||||||
|
@Suppress("SpellCheckingInspection")
|
||||||
|
val str = "kjsghkjshtiurhuig"
|
||||||
+13
@@ -3696,6 +3696,19 @@ public class QuickFixMultiFileTestGenerated extends AbstractQuickFixMultiFileTes
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@TestMetadata("idea/testData/quickfix/suppress/external")
|
||||||
|
@TestDataPath("$PROJECT_ROOT")
|
||||||
|
@RunWith(JUnit3RunnerWithInners.class)
|
||||||
|
public static class External extends AbstractQuickFixMultiFileTest {
|
||||||
|
private void runTest(String testDataFilePath) throws Exception {
|
||||||
|
KotlinTestUtils.runTest(this::doTestWithExtraFile, TargetBackend.ANY, testDataFilePath);
|
||||||
|
}
|
||||||
|
|
||||||
|
public void testAllFilesPresentInExternal() throws Exception {
|
||||||
|
KotlinTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("idea/testData/quickfix/suppress/external"), Pattern.compile("^(\\w+)\\.((before\\.Main\\.\\w+)|(test))$"), TargetBackend.ANY, true);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@TestMetadata("idea/testData/quickfix/suppress/forStatement")
|
@TestMetadata("idea/testData/quickfix/suppress/forStatement")
|
||||||
@TestDataPath("$PROJECT_ROOT")
|
@TestDataPath("$PROJECT_ROOT")
|
||||||
@RunWith(JUnit3RunnerWithInners.class)
|
@RunWith(JUnit3RunnerWithInners.class)
|
||||||
|
|||||||
@@ -10286,6 +10286,29 @@ public class QuickFixTestGenerated extends AbstractQuickFixTest {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@TestMetadata("idea/testData/quickfix/suppress/external")
|
||||||
|
@TestDataPath("$PROJECT_ROOT")
|
||||||
|
@RunWith(JUnit3RunnerWithInners.class)
|
||||||
|
public static class External extends AbstractQuickFixTest {
|
||||||
|
private void runTest(String testDataFilePath) throws Exception {
|
||||||
|
KotlinTestUtils.runTest(this::doTest, TargetBackend.ANY, testDataFilePath);
|
||||||
|
}
|
||||||
|
|
||||||
|
public void testAllFilesPresentInExternal() throws Exception {
|
||||||
|
KotlinTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("idea/testData/quickfix/suppress/external"), Pattern.compile("^([\\w\\-_]+)\\.kt$"), TargetBackend.ANY, true);
|
||||||
|
}
|
||||||
|
|
||||||
|
@TestMetadata("suppressActive.kt")
|
||||||
|
public void testSuppressActive() throws Exception {
|
||||||
|
runTest("idea/testData/quickfix/suppress/external/suppressActive.kt");
|
||||||
|
}
|
||||||
|
|
||||||
|
@TestMetadata("suppressAvailable.kt")
|
||||||
|
public void testSuppressAvailable() throws Exception {
|
||||||
|
runTest("idea/testData/quickfix/suppress/external/suppressAvailable.kt");
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@TestMetadata("idea/testData/quickfix/suppress/forStatement")
|
@TestMetadata("idea/testData/quickfix/suppress/forStatement")
|
||||||
@TestDataPath("$PROJECT_ROOT")
|
@TestDataPath("$PROJECT_ROOT")
|
||||||
@RunWith(JUnit3RunnerWithInners.class)
|
@RunWith(JUnit3RunnerWithInners.class)
|
||||||
|
|||||||
Reference in New Issue
Block a user