Skip to content
This repository has been archived by the owner on Jun 1, 2021. It is now read-only.

Commit

Permalink
Use await instead of whenReady in CRDT service spec
Browse files Browse the repository at this point in the history
- which is consistent with other tests
  • Loading branch information
krasserm committed Dec 21, 2016
1 parent 943aefa commit dec7fba
Showing 1 changed file with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -21,12 +21,11 @@ import akka.testkit._
import com.rbmhtechnology.eventuate.{ DurableEvent, SingleLocationSpecLeveldb }
import com.rbmhtechnology.eventuate.utilities._
import org.scalatest._
import org.scalatest.concurrent.ScalaFutures

import scala.concurrent.Future
import scala.util.{ Failure, Try }

class CRDTServiceSpecLeveldb extends TestKit(ActorSystem("test")) with WordSpecLike with Matchers with ScalaFutures with SingleLocationSpecLeveldb {
class CRDTServiceSpecLeveldb extends TestKit(ActorSystem("test")) with WordSpecLike with Matchers with SingleLocationSpecLeveldb {
"A CRDTService" must {
"manage multiple CRDTs identified by name" in {
val service = new CounterService[Int]("a", log)
Expand Down Expand Up @@ -58,7 +57,7 @@ class CRDTServiceSpecLeveldb extends TestKit(ActorSystem("test")) with WordSpecL
}

val service = new FailingAtPrepareCRDTService("a", log)
whenReady(service.operation("a").failed)(_ shouldBe a[PrepareException])
intercept[PrepareException](service.operation("a").await)
}
}

Expand Down

0 comments on commit dec7fba

Please sign in to comment.