final class ContainWord extends AnyRef
This class is part of the ScalaTest matchers DSL. Please see the documentation for Matchers for an overview of
the matchers DSL.
- Source
- ContainWord.scala
- Alphabetic
- By Inheritance
- ContainWord
- AnyRef
- Any
- Hide All
- Show All
- Public
- All
Instance Constructors
- new ContainWord()
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
- def allOf(firstEle: Any, secondEle: Any, remainingEles: Any*): MatcherFactory1[Any, Aggregating]
-
def
apply(nullValue: Null): MatcherFactory1[Any, Containing]
This method enables the following syntax:
This method enables the following syntax:
list should contain (null) ^ -
def
apply(expectedElement: Any): MatcherFactory1[Any, Containing]
This method enables the following syntax:
This method enables the following syntax:
Array(1, 2) should (contain (2) and contain (1)) ^ -
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
- def atLeastOneOf(firstEle: Any, secondEle: Any, remainingEles: Any*): MatcherFactory1[Any, Aggregating]
- def atMostOneOf(firstEle: Any, secondEle: Any, remainingEles: Any*): MatcherFactory1[Any, Aggregating]
-
def
clone(): AnyRef
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
finalize(): Unit
- Attributes
- protected[java.lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( classOf[java.lang.Throwable] )
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- def inOrder(firstEle: Any, secondEle: Any, remainingEles: Any*): MatcherFactory1[Any, Sequencing]
- def inOrderOnly(firstEle: Any, secondEle: Any, remainingEles: Any*): MatcherFactory1[Any, Sequencing]
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
-
def
key[K](expectedKey: Any): MatcherFactory1[Any, KeyMapping]
This method enables the following syntax:
This method enables the following syntax:
map should (contain key ("fifty five") or contain key ("twenty two")) ^The map's value type parameter cannot be inferred because only a key type is provided in an expression like
(contain key ("fifty five")). The matcher returned by this method matchesscala.collection.Maps with the inferred key type and value typeAny. GivenMapis covariant in its value type, andMatcheris contravariant in its type parameter, aMatcher[Map[Int, Any]], for example, is a subtype ofMatcher[Map[Int, String]]. This will enable the matcher returned by this method to be used against anyMapthat has the inferred key type. -
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
- def noneOf(firstEle: Any, secondEle: Any, remainingEles: Any*): MatcherFactory1[Any, Containing]
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- def oneOf(firstEle: Any, secondEle: Any, remainingEles: Any*): MatcherFactory1[Any, Containing]
- def only(right: Any*): MatcherFactory1[Any, Aggregating]
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
- def theSameElementsAs(right: GenTraversable[Any]): MatcherFactory1[Any, Aggregating]
- def theSameElementsInOrderAs(right: GenTraversable[Any]): MatcherFactory1[Any, Sequencing]
-
def
toString(): String
Overrides toString to return "contain"
Overrides toString to return "contain"
- Definition Classes
- ContainWord → AnyRef → Any
-
def
value[K](expectedValue: Any): MatcherFactory1[Any, ValueMapping]
This method enables the following syntax:
This method enables the following syntax:
Map("one" -> 1, "two" -> 2) should (not contain value (5) and not contain value (3)) ^The map's key type parameter cannot be inferred because only a value type is provided in an expression like
(contain value (5)). The matcher returned by this method matchesscala.collection.Maps with the inferred value type and the existential key type[K] forSome { type K }. Even thoughMatcheris contravariant in its type parameter, becauseMapis nonvariant in its key type, aMatcher[Map[Any, Int]], for example, is not a subtype ofMatcher[Map[String, Int]], so the key type parameter of theMapreturned by this method cannot beAny. By making it an existential type, the Scala compiler will not infer it to anything more specific. This will enable the matcher returned by this method to be used against anyMapthat has the inferred value type. -
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )