[K/JS] Add @deprecated commentary if @Deprecated annotation exists on a declaration.

^KT-56405 Fixed
This commit is contained in:
Artem Kobzar
2023-03-03 10:18:11 +00:00
committed by Space Team
parent 31a16ba72c
commit 4eb5af68f4
15 changed files with 337 additions and 7 deletions
@@ -121,6 +121,38 @@ public class IrJsTypeScriptExportTestGenerated extends AbstractIrJsTypeScriptExp
}
}
@Nested
@TestMetadata("js/js.translator/testData/typescript-export/deprecated")
@TestDataPath("$PROJECT_ROOT")
public class Deprecated {
@Test
public void testAllFilesPresentInDeprecated() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("js/js.translator/testData/typescript-export/deprecated"), Pattern.compile("^([^_](.+))\\.kt$"), null, TargetBackend.JS_IR, true);
}
@Test
@TestMetadata("deprecated.kt")
public void testDeprecated() throws Exception {
runTest("js/js.translator/testData/typescript-export/deprecated/deprecated.kt");
}
}
@Nested
@TestMetadata("js/js.translator/testData/typescript-export/deprecated-in-exported-file")
@TestDataPath("$PROJECT_ROOT")
public class Deprecated_in_exported_file {
@Test
public void testAllFilesPresentInDeprecated_in_exported_file() throws Exception {
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("js/js.translator/testData/typescript-export/deprecated-in-exported-file"), Pattern.compile("^([^_](.+))\\.kt$"), null, TargetBackend.JS_IR, true);
}
@Test
@TestMetadata("deprecated.kt")
public void testDeprecated() throws Exception {
runTest("js/js.translator/testData/typescript-export/deprecated-in-exported-file/deprecated.kt");
}
}
@Nested
@TestMetadata("js/js.translator/testData/typescript-export/enum-classes")
@TestDataPath("$PROJECT_ROOT")