Hamcrest

trait Hamcrest

This trait adds implicit conversions to be able to use Hamcrest matchers as specs2 matchers.

Companion:
object
class Object
trait Matchable
class Any
object Hamcrest.type

Value members

Concrete methods

def createKoMessageFromHamcrest[T](t: => T, hamcrest: Matcher[T]): String
Returns:

a string showing the matched value and the failure message from the Hamcrest matcher

Givens

Givens

given given_Conversion_Matcher_Matcher[T]: given_Conversion_Matcher_Matcher[T]

convert a Hamcrest matcher to a specs2 matcher

convert a Hamcrest matcher to a specs2 matcher