Files
kotlin-fork/js/js.translator/testData/box/expression/misc/throwThrow.kt
T
2018-09-12 09:49:25 +03:00

17 lines
284 B
Kotlin
Vendored

// EXPECTED_REACHABLE_NODES: 1284
package foo
fun test() {
throw throw Exception("catch me")
}
fun box(): String {
try {
test()
error("exception not thrown")
}
catch (e: Exception) {
assertEquals("catch me", e.message)
}
return "OK"
}