Fix failing WeightedRouteesSpec, see #2547

This commit is contained in:
Patrik Nordwall 2012-11-16 13:35:10 +01:00
parent 5d874fec17
commit 39d81b37df

View file

@ -40,7 +40,10 @@ class WeightedRouteesSpec extends AkkaSpec(ConfigFactory.parseString("""
"check boundaries" in {
val empty = new WeightedRoutees(Vector(), a1, Map.empty)
empty.total must be(0)
empty.isEmpty must be(true)
intercept[IllegalArgumentException] {
empty.total
}
val weighted = new WeightedRoutees(Vector(refA, refB, refC), a1, Map.empty)
weighted.total must be(3)
intercept[IllegalArgumentException] {