[Wasm] Add @WasmImport diagnostics (KT-56943)
WasmImport annotated functions: * Restricted to top-level external functions * Only supports primitive numbers, booleans and Unit (as return type only) in its signature * Can't have default parameter values * Can't have vararg parameters
This commit is contained in:
committed by
Space Team
parent
f79607d32d
commit
1da96213ca
+16
@@ -57,4 +57,20 @@ public class DiagnosticsWasmTestGenerated extends AbstractDiagnosticsWasmTest {
|
||||
runTest("compiler/testData/diagnostics/wasmTests/jsInterop/jsExport.kt");
|
||||
}
|
||||
}
|
||||
|
||||
@Nested
|
||||
@TestMetadata("compiler/testData/diagnostics/wasmTests/wasmInterop")
|
||||
@TestDataPath("$PROJECT_ROOT")
|
||||
public class WasmInterop {
|
||||
@Test
|
||||
public void testAllFilesPresentInWasmInterop() throws Exception {
|
||||
KtTestUtil.assertAllTestsPresentByMetadataWithExcluded(this.getClass(), new File("compiler/testData/diagnostics/wasmTests/wasmInterop"), Pattern.compile("^(.+)\\.kt$"), null, true);
|
||||
}
|
||||
|
||||
@Test
|
||||
@TestMetadata("wasmImport.kt")
|
||||
public void testWasmImport() throws Exception {
|
||||
runTest("compiler/testData/diagnostics/wasmTests/wasmInterop/wasmImport.kt");
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user