Pure scala mock for scala-redis
Only these versions are tested.
scala-redis-mock | scala-redis | redis-server |
---|---|---|
0.1.1 | 2.15 | 2.8.19 |
N/A | 3.0 | 2.8.19 |
$ cd your_work_dir
$ git clone git@github.com:mogproject/scala-redis-mock.git
$ cd scala-redis-mock
$ sbt console
scala> r.set("foo", "bar")
res0: Boolean = true
scala> r.get("foo")
res1: Option[String] = Some(bar)
- With mock
sbt test
- With real redis-server
You need to install Redis in the local host.
redis-server &
USE_REAL_REDIS=yes sbt test
redis-cli shutdown
Connection
,Keys
,String
,Lists
,Sets
,Sorted Sets
,Hashes
,HyperLogLog
The following features are not supported.
Server
,Scripting
,Pub/Sub
,Transactions
,Cluster