KJS: add multimodule version of inheritFromRenamedNativeClass

This commit is contained in:
Zalim Bashorov
2016-11-17 14:16:41 +03:00
parent 8c630954a8
commit ef11393462
4 changed files with 41 additions and 6 deletions
@@ -4976,9 +4976,15 @@ public class BoxJsTestGenerated extends AbstractBoxJsTest {
doTest(fileName);
}
@TestMetadata("inherietFromRenamedNativeClass.kt")
public void testInherietFromRenamedNativeClass() throws Exception {
String fileName = KotlinTestUtils.navigationMetadata("js/js.translator/testData/box/jsName/inherietFromRenamedNativeClass.kt");
@TestMetadata("inheritFromRenamedNativeClass.kt")
public void testInheritFromRenamedNativeClass() throws Exception {
String fileName = KotlinTestUtils.navigationMetadata("js/js.translator/testData/box/jsName/inheritFromRenamedNativeClass.kt");
doTest(fileName);
}
@TestMetadata("inheritFromRenamedNativeClassMultimodule.kt")
public void testInheritFromRenamedNativeClassMultimodule() throws Exception {
String fileName = KotlinTestUtils.navigationMetadata("js/js.translator/testData/box/jsName/inheritFromRenamedNativeClassMultimodule.kt");
doTest(fileName);
}
@@ -1,3 +0,0 @@
function A(foo) {
this.foo = foo;
}
@@ -1,3 +1,5 @@
// FILE: main.kt
package foo
@native
@@ -8,4 +10,10 @@ class C(s: String) : B(s)
fun box(): String {
return C("OK").foo
}
// FILE: test.js
function A(foo) {
this.foo = foo;
}
@@ -0,0 +1,24 @@
// MODULE: module1
// FILE: module1.kt
package foo
@native
@JsName("A")
open class B(val foo: String)
// MODULE: main(module1)
// FILE: main.kt
package foo
class C(s: String) : B(s)
fun box(): String {
return C("OK").foo
}
// FILE: test.js
function A(foo) {
this.foo = foo;
}