Trait/Object

org.scalatest.enablers

ValueMapping

Related Docs: object ValueMapping | package enablers

Permalink

trait ValueMapping[-M] extends AnyRef

Supertrait for typeclasses that enable contain value matcher syntax.

A ValueMapping[M] provides access to the "value mapping nature" of type M in such a way that contain value matcher syntax can be used with type M. An M can be any type for which contain value syntax makes sense. ScalaTest provides implicit implementations for scala.collection.GenMap and java.util.Map. You can enable the contain value matcher syntax on your own type U by defining a ValueMapping[U] for the type and making it available implicitly.

ScalaTest provides implicit ValueMapping instances for scala.collection.GenMap, and java.util.Map in the ValueMapping companion object.

Source
ValueMapping.scala
Linear Supertypes
AnyRef, Any
Ordering
  1. Alphabetic
  2. By inheritance
Inherited
  1. ValueMapping
  2. AnyRef
  3. Any
  1. Hide All
  2. Show all
Visibility
  1. Public
  2. All

Abstract Value Members

  1. abstract def containsValue(map: M, value: Any): Boolean

    Permalink

    Check if the passed map contains the passed value.

    Check if the passed map contains the passed value.

    map

    a map about which an assertion is being made

    value

    value of which should be contained in the passed map

    returns

    true if the passed map contains the passed value