Permalink
Browse files

Only the weight ordering matters for SqlShard.listDownwardLinks

  • Loading branch information...
1 parent fca29ee commit 066c1ce03cd254ad6bb4972794d79ec7cf201898 @stuhood stuhood committed Feb 24, 2012
Showing with 5 additions and 2 deletions.
  1. +5 −2 src/test/scala/com/twitter/gizzard/nameserver/SqlShardSpec.scala
@@ -237,8 +237,11 @@ class SqlShardSpec extends ConfiguredSpecification with JMocker with ClassMocker
nsShard.addLink(shard(1), shard(100), 2)
nsShard.addLink(shard(1), shard(200), 2)
nsShard.addLink(shard(1), shard(300), 1)
- nsShard.listDownwardLinks(shard(1)) mustEqual
- List(link(100, 2), link(200, 2), link(300, 1))
+ nsShard.listDownwardLinks(shard(1)) must beOneOf(
+ // only the ordering of weights matters
+ List(link(100, 2), link(200, 2), link(300, 1)),
+ List(link(200, 2), link(100, 2), link(300, 1))
+ )
}
"remove" >> {

0 comments on commit 066c1ce

Please sign in to comment.