Minor. Use more granular assertion levels in assertion tests
This commit is contained in:
@@ -3,6 +3,8 @@
|
||||
// KOTLIN_CONFIGURATION_FLAGS: ASSERTIONS_MODE=jvm
|
||||
// WITH_RUNTIME
|
||||
|
||||
package interfaceAssertionsEnabled
|
||||
|
||||
interface Checker {
|
||||
fun checkTrue(): Boolean {
|
||||
var hit = false
|
||||
@@ -39,8 +41,8 @@ class Dummy
|
||||
|
||||
fun enableAssertions(): Checker {
|
||||
val loader = Dummy::class.java.classLoader
|
||||
loader.setDefaultAssertionStatus(true)
|
||||
val c = loader.loadClass("ShouldBeEnabled")
|
||||
loader.setPackageAssertionStatus("interfaceAssertionsEnabled", true)
|
||||
val c = loader.loadClass("interfaceAssertionsEnabled.ShouldBeEnabled")
|
||||
return c.newInstance() as Checker
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user