main.misk.redis.RedisTestModule.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of misk-redis Show documentation
Show all versions of misk-redis Show documentation
Open source application container in Kotlin
package misk.redis
import misk.inject.KAbstractModule
import jakarta.inject.Qualifier
import kotlin.random.Random
@Deprecated("Moved to misk-redis-testing.", ReplaceWith("misk.redis.testing.RedisTestModule"))
class RedisTestModule @JvmOverloads constructor(private val random: Random = Random.Default) :
KAbstractModule() {
override fun configure() {
bind().annotatedWith().toInstance(random)
bind().toInstance(FakeRedis())
}
}
@Qualifier
@Retention(AnnotationRetention.RUNTIME)
@Target(AnnotationTarget.FIELD)
@Deprecated("Moved to misk-redis-testing.", ReplaceWith("misk.redis.testing.ForFakeRedis"))
annotation class ForFakeRedis