JsonMatchers

org.specs2.matcher.JsonMatchers
See theJsonMatchers companion object
trait JsonMatchers

Matchers for Json expressions (entered as strings)

Attributes

Companion
object
Graph
Supertypes
trait Expectations
trait ExpectationsDescription
trait TypedEqual
trait ExpectationsCreation
trait MatchResultStackTrace
class Object
trait Matchable
class Any
Show all
Known subtypes
object JsonMatchers.type

Members list

Type members

Inherited classlikes

case object Deep extends JsonQueryType

Attributes

Inherited from:
JsonSelectors
Supertypes
trait Singleton
trait Product
trait Mirror
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all
class Descriptible[T](value: => T)

Attributes

Inherited from:
ExpectationsDescription
Supertypes
class Object
trait Matchable
class Any
class ExpectationDescription(description: String)

Attributes

Inherited from:
ExpectationsDescription
Supertypes
class Object
trait Matchable
class Any
case object First extends JsonQueryType

Attributes

Inherited from:
JsonSelectors
Supertypes
trait Singleton
trait Product
trait Mirror
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all
case class JsonDoubleSelector(d: Double) extends JsonSelector

Attributes

Inherited from:
JsonSelectors
Supertypes
trait Serializable
trait Product
trait Equals
trait JsonSelector
class Object
trait Matchable
class Any
Show all
case class JsonEqualValueSelector(v: Any) extends JsonSelector

Attributes

Inherited from:
JsonSelectors
Supertypes
trait Serializable
trait Product
trait Equals
trait JsonSelector
class Object
trait Matchable
class Any
Show all
case class JsonFinalMatcher(queries: Seq[JsonQuery], check: Matcher[JsonType], negated: Boolean) extends JsonMatcher

This matcher can not be chained anymore with selections

This matcher can not be chained anymore with selections

Attributes

Inherited from:
JsonBaseMatchers (hidden)
Supertypes
trait Serializable
trait Product
trait Equals
class JsonMatcher
trait Matcher[String]
class Object
trait Matchable
class Any
Show all
case class JsonIndexSelector(n: Int) extends JsonSelector

Attributes

Inherited from:
JsonSelectors
Supertypes
trait Serializable
trait Product
trait Equals
trait JsonSelector
class Object
trait Matchable
class Any
Show all
case class JsonIntSelector(n: Int) extends JsonSelector

Attributes

Inherited from:
JsonSelectors
Supertypes
trait Serializable
trait Product
trait Equals
trait JsonSelector
class Object
trait Matchable
class Any
Show all
abstract class JsonMatcher extends Matcher[String]

Attributes

Inherited from:
JsonBaseMatchers (hidden)
Supertypes
trait Matcher[String]
class Object
trait Matchable
class Any
Known subtypes
object JsonMatcher

Attributes

Inherited from:
JsonBaseMatchers (hidden)
Supertypes
class Object
trait Matchable
class Any
case class JsonMatcherSelector(m: Matcher[String]) extends JsonSelector

Attributes

Inherited from:
JsonSelectors
Supertypes
trait Serializable
trait Product
trait Equals
trait JsonSelector
class Object
trait Matchable
class Any
Show all

Attributes

Inherited from:
JsonSelectors
Supertypes
trait Serializable
trait Product
trait Equals
trait JsonSelector
class Object
trait Matchable
class Any
Show all
case class JsonQuery(query: JsonQueryType, selector: JsonSelector)

Attributes

Inherited from:
JsonSelectors
Supertypes
trait Serializable
trait Product
trait Equals
class Object
trait Matchable
class Any
Show all
sealed trait JsonQueryType

Attributes

Inherited from:
JsonSelectors
Supertypes
class Object
trait Matchable
class Any
Known subtypes
object Deep.type
object First.type
case class JsonRegexSelector(r: Regex) extends JsonSelector

Attributes

Inherited from:
JsonSelectors
Supertypes
trait Serializable
trait Product
trait Equals
trait JsonSelector
class Object
trait Matchable
class Any
Show all
sealed trait JsonSelector

Attributes

Inherited from:
JsonSelectors
Supertypes
class Object
trait Matchable
class Any
Known subtypes
case class JsonSelectorMatcher(queries: Seq[JsonQuery], negated: Boolean) extends JsonMatcher

This matcher can be chained to select further elements in the Json object

This matcher can be chained to select further elements in the Json object

Attributes

Inherited from:
JsonBaseMatchers (hidden)
Supertypes
trait Serializable
trait Product
trait Equals
class JsonMatcher
trait Matcher[String]
class Object
trait Matchable
class Any
Show all
case class JsonValueOrKeySelector(selector: JsonSelector) extends JsonSelector

Attributes

Inherited from:
JsonSelectors
Supertypes
trait Serializable
trait Product
trait Equals
trait JsonSelector
class Object
trait Matchable
class Any
Show all
class NotMatcherJson(result: NotMatcher[Any])

Attributes

Inherited from:
JsonBaseBeHaveMatchers (hidden)
Supertypes
class Object
trait Matchable
class Any

Attributes

Inherited from:
JsonMatchersImplicits (hidden)
Supertypes
class Object
trait Matchable
class Any
trait ToJsonSelector[T]

Attributes

Inherited from:
JsonMatchersLowImplicits (hidden)
Supertypes
class Object
trait Matchable
class Any
class TypedEqualExpectation[T](t: => T)

Attributes

Inherited from:
TypedEqual
Supertypes
class Object
trait Matchable
class Any

Value members

Inherited methods

Attributes

Inherited from:
JsonBaseMatchers (hidden)

Attributes

Inherited from:
JsonBaseMatchers (hidden)
def /#(n: Int): JsonSelectorMatcher

Attributes

Inherited from:
JsonBaseMatchers (hidden)
def anyValue: Matcher[String]

Attributes

Inherited from:
JsonSelectors
def be: NeutralMatcher[Any]

Attributes

Inherited from:
BeHaveMatchers (hidden)
def beJsonNull: Matcher[JsonType]

Attributes

Inherited from:
JsonBaseMatchers (hidden)
protected def checkFailure[T](m: MatchResult[T]): MatchResult[T]

this method can be overridden to throw exceptions when checking the match result

this method can be overridden to throw exceptions when checking the match result

Attributes

Inherited from:
ExpectationsCreation
protected def checkMatchResultFailure[T](m: MatchResult[T]): MatchResult[T]

this method can be overridden to throw exceptions when checking the match result

this method can be overridden to throw exceptions when checking the match result

Attributes

Inherited from:
ExpectationsCreation
protected def checkResultFailure(r: => Result): Result

this method can be overridden to throw exceptions when checking the result

this method can be overridden to throw exceptions when checking the result

Attributes

Inherited from:
ExpectationsCreation
def createExpectable[T](t: => T, alias: Option[String => String]): Expectable[T]

Attributes

Returns

an Expectable with a description function

Inherited from:
ExpectationsCreation
def createExpectable[T](t: => T, alias: String => String): Expectable[T]

Attributes

Returns

an Expectable with a description function

Inherited from:
ExpectationsCreation
def createExpectable[T](t: => T, alias: => String): Expectable[T]

Attributes

Returns

an Expectable with a description

Inherited from:
ExpectationsCreation
def createExpectable[T](t: => T): Expectable[T]

Attributes

Returns

an Expectable

Inherited from:
ExpectationsCreation
def createExpectableWithShowAs[T](t: => T, showAs: => String): Expectable[T]

Attributes

Returns

an Expectable with a function to show the element T

Inherited from:
ExpectationsCreation
def have: NeutralMatcher[Any]

Attributes

Inherited from:
BeHaveMatchers (hidden)
def have(m: Matcher[JsonType]): JsonMatcher

Attributes

Inherited from:
JsonBaseMatchers (hidden)
protected def mapMatchResult[T](m: MatchResult[T]): MatchResult[T]

this method can be overridden to intercept a MatchResult and change its message before it is thrown

this method can be overridden to intercept a MatchResult and change its message before it is thrown

Attributes

Inherited from:
ExpectationsCreation
def not: NotMatcher[Any]

Attributes

Inherited from:
BeHaveMatchers (hidden)
protected def sandboxMatchResult[T](mr: => MatchResult[T]): MatchResult[T]

Attributes

Returns

the match result without any side-effects

Inherited from:
ExpectationsCreation
protected def setStacktrace[T](m: MatchResult[T]): MatchResult[T]

this method can be overridden to avoid filling-in a stacktrace indicating the location of the result

this method can be overridden to avoid filling-in a stacktrace indicating the location of the result

Attributes

Inherited from:
MatchResultStackTrace

Implicits

Inherited implicits

implicit def booleanToJsonSelector: ToJsonSelector[Boolean]

Attributes

Inherited from:
JsonMatchersLowImplicits (hidden)
implicit def describe[T](t: => T): Descriptible[T]

describe a value with the aka method

describe a value with the aka method

Attributes

Inherited from:
ExpectationsDescription
implicit def describeExpectation(description: String): ExpectationDescription

Attributes

Inherited from:
ExpectationsDescription
implicit def doubleToJsonSelector: ToJsonSelector[Double]

Attributes

Inherited from:
JsonMatchersLowImplicits (hidden)
implicit def intToJsonSelector: ToJsonSelector[Int]

Attributes

Inherited from:
JsonMatchersLowImplicits (hidden)
implicit def matcherToJsonSelector[M <: Matcher[String]]: ToJsonSelector[M]

Attributes

Inherited from:
JsonMatchersImplicits (hidden)
implicit def regexToJsonSelector: ToJsonSelector[Regex]

Attributes

Inherited from:
JsonMatchersImplicits (hidden)
implicit def stringToJsonSelector: ToJsonSelector[String]

Attributes

Inherited from:
JsonMatchersLowImplicits (hidden)
implicit def toJsonSelectorBooleanValue(b: Boolean): JsonSelector

Attributes

Inherited from:
JsonMatchersImplicits (hidden)
implicit def toJsonSelectorDoubleValue(d: Double): JsonSelector

Attributes

Inherited from:
JsonMatchersImplicits (hidden)
implicit def toJsonSelectorIntValue(i: Int): JsonSelector

Attributes

Inherited from:
JsonMatchersImplicits (hidden)

Attributes

Inherited from:
JsonMatchersImplicits (hidden)
implicit def toJsonSelectorRegex(r: Regex): JsonSelector

Attributes

Inherited from:
JsonMatchersImplicits (hidden)
implicit def toJsonSelectorStringMatcher[M <: Matcher[String]](m: M): JsonSelector

datatype to specify how json values must be checked

datatype to specify how json values must be checked

Attributes

Inherited from:
JsonMatchersImplicits (hidden)
implicit def toJsonSelectorStringValue(s: String): JsonSelector

Attributes

Inherited from:
JsonMatchersImplicits (hidden)
implicit def toNotMatcherJson(result: NotMatcher[Any]): NotMatcherJson

Attributes

Inherited from:
JsonBaseBeHaveMatchers (hidden)
implicit def typedEqualExpectation[T](t: => T): TypedEqualExpectation[T]

A value can be tested against another with the === operator. It is equivalent to writing a must_== b

A value can be tested against another with the === operator. It is equivalent to writing a must_== b

Attributes

Inherited from:
TypedEqual