problem: Kotlin class mocking randomly fails
solution: upgrade testing libs, and open the class
This commit is contained in:
@@ -10,7 +10,7 @@ import reactor.netty.http.client.HttpClient
|
||||
import java.util.*
|
||||
import java.util.function.Consumer
|
||||
|
||||
class BitcoinRpcClient(
|
||||
open class BitcoinRpcClient(
|
||||
private val target: String,
|
||||
basicAuth: AuthConfig.ClientBasicAuth?
|
||||
) {
|
||||
|
||||
@@ -1,22 +1,14 @@
|
||||
package io.emeraldpay.dshackle.upstream.bitcoin
|
||||
|
||||
import de.jodamob.kotlin.testrunner.OpenedClasses
|
||||
import de.jodamob.kotlin.testrunner.SpotlinTestRunner
|
||||
import io.emeraldpay.dshackle.test.TestingCommons
|
||||
import org.junit.runner.RunWith
|
||||
import org.mockserver.integration.ClientAndServer
|
||||
import reactor.core.publisher.Mono
|
||||
import reactor.test.StepVerifier
|
||||
import spock.lang.Specification
|
||||
|
||||
import java.time.Duration
|
||||
|
||||
@RunWith(SpotlinTestRunner)
|
||||
@OpenedClasses(BitcoinApi)
|
||||
class BitcoinRpcHeadSpec extends Specification {
|
||||
|
||||
ClientAndServer mockServer
|
||||
|
||||
def "Follow 2 blocks created over 3 requests"() {
|
||||
setup:
|
||||
String hash1 = "0000000000000000000cf5a5d4dfc4347c0c1a863ec5fdb429b02b2162e50001"
|
||||
|
||||
Reference in New Issue
Block a user