org.specs2.scalacheck
This object can be used to create Pretty instances for case class Where string attributes are being quoted for easier copy/pasting from the console when it is needed to replay a failing example. Usage:
case class MyInt(i: Int, s: String = "hey")
object MyInt { implicit def ArbInt: Arbitrary[MyInt] = Arbitrary(Gen.const(MyInt(1))) implicit def pretty: MyInt => Pretty = PrettyProduct[MyInt] }
This object can be used to create Pretty instances for case class Where string attributes are being quoted for easier copy/pasting from the console when it is needed to replay a failing example. Usage:
case class MyInt(i: Int, s: String = "hey")
object MyInt { implicit def ArbInt: Arbitrary[MyInt] = Arbitrary(Gen.const(MyInt(1))) implicit def pretty: MyInt => Pretty = PrettyProduct[MyInt] }