ScalaTest 1.1
|
|
final
class
MapShouldWrapper[K, V](left : scala.collection.Map[K, V])
extends
AnyRefShouldMatchers
or MustMatchers
for an overview of
the matchers DSL.
This class is used in conjunction with an implicit conversion to enable should
methods to
be invoked on objects of type scala.collection.Map[K, V]
.
Method Summary | |
def
|
should
(haveWord : HaveWord) : ResultOfHaveWordForCollection[(K, V)]
This method enables syntax such as the following:
map should have size (3) ^ |
def
|
should
(notWord : NotWord) : ResultOfNotWordForMap[K, V]
This method enables syntax such as the following:
map should not have size (3) ^ |
def
|
should
(beWord : BeWord) : ResultOfBeWordForAnyRef[scala.collection.Map[K, V]]
This method enables syntax such as the following:
map should be theSameInstanceAs (anotherMap) ^ |
def
|
should
(containWord : ContainWord) : ResultOfContainWordForMap[K, V]
This method enables syntax such as the following:
map should contain key (10) ^ |
def
|
should
(rightMatcher : Matcher[scala.collection.Map[K, V]]) : Unit
This method enables syntax such as the following:
map should equal (Map(1 -> "one", 2 -> "two")) ^ |
Methods inherited from AnyRef | |
getClass, hashCode, equals, clone, toString, notify, notifyAll, wait, wait, wait, finalize, ==, !=, eq, ne, synchronized |
Methods inherited from Any | |
==, !=, isInstanceOf, asInstanceOf |
Method Details |
def
should(rightMatcher : Matcher[scala.collection.Map[K, V]]) : Unit
map should equal (Map(1 -> "one", 2 -> "two")) ^
def
should(beWord : BeWord) : ResultOfBeWordForAnyRef[scala.collection.Map[K, V]]
map should be theSameInstanceAs (anotherMap) ^
def
should(haveWord : HaveWord) : ResultOfHaveWordForCollection[(K, V)]
map should have size (3) ^
def
should(containWord : ContainWord) : ResultOfContainWordForMap[K, V]
map should contain key (10) ^
def
should(notWord : NotWord) : ResultOfNotWordForMap[K, V]
map should not have size (3) ^
ScalaTest 1.1
|
|