JS: move more test to box tests
This commit is contained in:
+18
@@ -0,0 +1,18 @@
|
||||
package foo
|
||||
|
||||
fun testIf(flag: Boolean): Int = js("""
|
||||
if (flag)
|
||||
return 1;
|
||||
else
|
||||
return -1;
|
||||
|
||||
return 0;
|
||||
""")
|
||||
|
||||
|
||||
fun box(): String {
|
||||
assertEquals(1, testIf(true))
|
||||
assertEquals(-1, testIf(false))
|
||||
|
||||
return "OK"
|
||||
}
|
||||
Reference in New Issue
Block a user