Companion object for Prettifier that provides a default Prettifier implementation.
- Companion:
- class
- Source:
- Prettifier.scala
Value members
Concrete methods
Constract a new Prettifier from a given partial function.
Constract a new Prettifier from a given partial function.
- Value parameters:
- fun
a partial function with which to implement the apply method of the returned
Prettifier.
- Source:
- Prettifier.scala
Construct a new Prettifier with given prettifier and customDiffer.
Construct a new Prettifier with given prettifier and customDiffer.
- Value parameters:
- fun
a partial function with which to implement the apply method of the returned
Prettifier.- prettifier
the base prettifer that the new prettifier will delegate apply(o: Any) to.
- Source:
- Prettifier.scala
Create a default prettifier instance with collection size limit.
Create a default prettifier instance with collection size limit.
- Source:
- Prettifier.scala
Concrete fields
A basic Prettifier.
A basic Prettifier.
This was the default Prettifier used in ScalaTest 2.0 release.
It transforms:
-
Nullto:null -
Unitto:<() the Unit value> -
Stringto:"string"(thetoStringresult surrounded by double quotes) -
Charto:'c'(thetoStringresult surrounded by single quotes) -
Arrayto:Array("1", "2", "3") -
scala.util.Someto:Some("3")
For anything else, it returns the result of invoking toString.
- Source:
- Prettifier.scala
Implicits
Implicits
A default Prettifier.
A default Prettifier.
This default Prettifier is used in ScalaTest to clarify error messages.
It transforms:
-
Nullto:null -
Unitto:<() the Unit value> -
Stringto:"string"(thetoStringresult surrounded by double quotes) -
Charto:'c'(thetoStringresult surrounded by single quotes) -
Arrayto:Array("1", "2", "3") -
scala.Someto:Some("3") -
scala.util.Leftto:Left("3") -
scala.util.Rightto:Right("3") -
scala.util.Successto:Success("3") -
org.scalactic.Goodto:Good("3") -
org.scalactic.Badto:Bad("3") -
org.scalactic.Oneto:One("3") -
org.scalactic.Manyto:Many("1", "2", "3") -
scala.collection.Iterableto:List("1", "2", "3") -
java.util.Collectionto:["1", "2", "3"] -
java.util.Mapto:{1="one", 2="two", 3="three"}
For anything else, it returns the result of invoking toString.
- Source:
- Prettifier.scala