JS/Inlining: add test case for KT-10931
This commit is contained in:
+6
@@ -89,6 +89,12 @@ public class InlineMultiModuleTestGenerated extends AbstractInlineMultiModuleTes
|
||||
doTest(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("parameterWithDefaultValue")
|
||||
public void testParameterWithDefaultValue() throws Exception {
|
||||
String fileName = KotlinTestUtils.navigationMetadata("js/js.translator/testData/inlineMultiModule/cases/parameterWithDefaultValue/");
|
||||
doTest(fileName);
|
||||
}
|
||||
|
||||
@TestMetadata("simple")
|
||||
public void testSimple() throws Exception {
|
||||
String fileName = KotlinTestUtils.navigationMetadata("js/js.translator/testData/inlineMultiModule/cases/simple/");
|
||||
|
||||
+3
@@ -0,0 +1,3 @@
|
||||
package foo
|
||||
|
||||
inline fun bar(x: Int = 0) = x + 10
|
||||
+10
@@ -0,0 +1,10 @@
|
||||
package foo
|
||||
|
||||
// CHECK_NOT_CALLED: bar
|
||||
|
||||
fun box(): String {
|
||||
assertEquals(10, bar())
|
||||
assertEquals(11, bar(1))
|
||||
|
||||
return "OK"
|
||||
}
|
||||
Reference in New Issue
Block a user