Introduce action to add missing when branches on sealed class

Made via diagnostics NON_EXHAUSTIVE_WHEN_FOR_SEALED_CLASS
with INFO severity and quick-fix
So #KT-17580 Fixed
This commit is contained in:
fitermay
2017-05-10 22:56:06 -04:00
committed by Mikhail Glukhikh
parent 1072495001
commit e30b9758f4
12 changed files with 124 additions and 3 deletions
@@ -10957,6 +10957,12 @@ public class QuickFixTestGenerated extends AbstractQuickFixTest {
doTest(fileName);
}
@TestMetadata("addRemainingBranchesSealedStatement.kt")
public void testAddRemainingBranchesSealedStatement() throws Exception {
String fileName = KotlinTestUtils.navigationMetadata("idea/testData/quickfix/when/addRemainingBranchesSealedStatement.kt");
doTest(fileName);
}
public void testAllFilesPresentInWhen() throws Exception {
KotlinTestUtils.assertAllTestsPresentByMetadata(this.getClass(), new File("idea/testData/quickfix/when"), Pattern.compile("^([\\w\\-_]+)\\.kt$"), TargetBackend.ANY, true);
}