raniejade
03/09/2017, 1:59 PMclass CustomInstanceFactory: InstanceFactory {
override fun <T: Spek> create(spek: KClass<T>): T {
return spek.objectInstance ?: spek.constructors.first { it.parameters.isEmpty() }
.call()
}
}
@CreateWith(CustomInstanceFactory::class)
open class MySpec(...): Spek({ ... })