Commit 5929233c authored by ryoii's avatar ryoii

Fix JvmMethodEventsTest.kt

parent 07d9365d
......@@ -11,12 +11,12 @@
package net.mamoe.mirai.event
import junit.framework.TestCase.assertEquals
import kotlinx.coroutines.CoroutineScope
import net.mamoe.mirai.utils.internal.runBlocking
import org.junit.Test
import java.util.concurrent.atomic.AtomicInteger
import kotlin.coroutines.EmptyCoroutineContext
import kotlin.test.assertEquals
internal class JvmMethodEventsTest {
......@@ -88,15 +88,15 @@ internal class JvmMethodEventsTest {
}
}
TestClass().run {
this.registerEvents()
runBlocking {
TestEvent().broadcast()
}
assertEquals(9, this.getCalled())
}
// TestClass().run {
// this.registerEvents()
//
// runBlocking {
// TestEvent().broadcast()
// }
//
// assertEquals(9, this.getCalled())
// }
}
@Test
......@@ -121,14 +121,14 @@ internal class JvmMethodEventsTest {
}
}
TestClass().run {
this.registerEvents()
runBlocking {
TestEvent().broadcast()
}
assertEquals(1, this.getCalled())
}
// TestClass().run {
// this.registerEvents()
//
// runBlocking {
// TestEvent().broadcast()
// }
//
// assertEquals(1, this.getCalled())
// }
}
}
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment