scalacheck

trait Testable

[source: scalacheck/Testable.scala]

trait Testable
extends AnyRef
Direct Known Subclasses:
Gen, Prop

Type Summary
type NamedPropEvalCallback
type TestStatsCallback
Method Summary
def allProperties : Prop
Returns all properties combined into a single property, that holds when all properties hold
def checkProperties (prms : Params) : Map[String, Stats]
Tests all properties with the given testing parameters, and returns the test results.
def checkProperties : Map[String, Stats]
Tests all properties with default testing parameters, and returns the test results. The results are also printed on the console during testing.
def checkProperties (prms : Params, propCallback : Function4, testCallback : Function2) : Map[String, Stats]
Tests all properties with the given testing parameters, and returns the test results. f is a function which is called each time a property is evaluted. g is a function called each time a property has been fully tested.
protected def specify [A1, A2, A3, P](propName : String, f : (A1, A2, A3) => P)(implicit p : (P) => Prop, implicit a1 : (Arb[A1]) => Arbitrary[A1], implicit a2 : (Arb[A2]) => Arbitrary[A2], implicit a3 : (Arb[A3]) => Arbitrary[A3]) : Unit
protected def specify [A1, A2, P](propName : String, f : (A1, A2) => P)(implicit p : (P) => Prop, implicit a1 : (Arb[A1]) => Arbitrary[A1], implicit a2 : (Arb[A2]) => Arbitrary[A2]) : Unit
protected def specify (propName : String, prop : => Prop) : Unit
protected def specify [A1, A2, A3, A4, P](propName : String, f : (A1, A2, A3, A4) => P)(implicit p : (P) => Prop, implicit a1 : (Arb[A1]) => Arbitrary[A1], implicit a2 : (Arb[A2]) => Arbitrary[A2], implicit a3 : (Arb[A3]) => Arbitrary[A3], implicit a4 : (Arb[A4]) => Arbitrary[A4]) : Unit
protected def specify [A1, A2, A3, A4, A5, A6, P](propName : String, f : (A1, A2, A3, A4, A5, A6) => P)(implicit p : (P) => Prop, implicit a1 : (Arb[A1]) => Arbitrary[A1], implicit a2 : (Arb[A2]) => Arbitrary[A2], implicit a3 : (Arb[A3]) => Arbitrary[A3], implicit a4 : (Arb[A4]) => Arbitrary[A4], implicit a5 : (Arb[A5]) => Arbitrary[A5], implicit a6 : (Arb[A6]) => Arbitrary[A6]) : Unit
protected def specify [A1, A2, A3, A4, A5, P](propName : String, f : (A1, A2, A3, A4, A5) => P)(implicit p : (P) => Prop, implicit a1 : (Arb[A1]) => Arbitrary[A1], implicit a2 : (Arb[A2]) => Arbitrary[A2], implicit a3 : (Arb[A3]) => Arbitrary[A3], implicit a4 : (Arb[A5]) => Arbitrary[A5], implicit a5 : (Arb[A4]) => Arbitrary[A4]) : Unit
protected def specify [A1, P](propName : String, f : (A1) => P)(implicit p : (P) => Prop, implicit a1 : (Arb[A1]) => Arbitrary[A1]) : Unit
def testCases : scala.List[TestCase]
Returns all properties as SUnit.TestCase instances, which can added to a SUnit.TestSuite.
Methods inherited from AnyRef
getClass, hashCode, equals, clone, toString, notify, notifyAll, wait, wait, wait, finalize, ==, !=, eq, ne, synchronized
Methods inherited from Any
==, !=, isInstanceOf, asInstanceOf
Type Details
type NamedPropEvalCallback

type TestStatsCallback

Method Details
protected def specify(propName : String, prop : => Prop) : Unit

protected def specify[A1, P](propName : String, f : (A1) => P)(implicit p : (P) => Prop, implicit a1 : (Arb[A1]) => Arbitrary[A1]) : Unit

protected def specify[A1, A2, P](propName : String, f : (A1, A2) => P)(implicit p : (P) => Prop, implicit a1 : (Arb[A1]) => Arbitrary[A1], implicit a2 : (Arb[A2]) => Arbitrary[A2]) : Unit

protected def specify[A1, A2, A3, P](propName : String, f : (A1, A2, A3) => P)(implicit p : (P) => Prop, implicit a1 : (Arb[A1]) => Arbitrary[A1], implicit a2 : (Arb[A2]) => Arbitrary[A2], implicit a3 : (Arb[A3]) => Arbitrary[A3]) : Unit

protected def specify[A1, A2, A3, A4, P](propName : String, f : (A1, A2, A3, A4) => P)(implicit p : (P) => Prop, implicit a1 : (Arb[A1]) => Arbitrary[A1], implicit a2 : (Arb[A2]) => Arbitrary[A2], implicit a3 : (Arb[A3]) => Arbitrary[A3], implicit a4 : (Arb[A4]) => Arbitrary[A4]) : Unit

protected def specify[A1, A2, A3, A4, A5, P](propName : String, f : (A1, A2, A3, A4, A5) => P)(implicit p : (P) => Prop, implicit a1 : (Arb[A1]) => Arbitrary[A1], implicit a2 : (Arb[A2]) => Arbitrary[A2], implicit a3 : (Arb[A3]) => Arbitrary[A3], implicit a4 : (Arb[A5]) => Arbitrary[A5], implicit a5 : (Arb[A4]) => Arbitrary[A4]) : Unit

protected def specify[A1, A2, A3, A4, A5, A6, P](propName : String, f : (A1, A2, A3, A4, A5, A6) => P)(implicit p : (P) => Prop, implicit a1 : (Arb[A1]) => Arbitrary[A1], implicit a2 : (Arb[A2]) => Arbitrary[A2], implicit a3 : (Arb[A3]) => Arbitrary[A3], implicit a4 : (Arb[A4]) => Arbitrary[A4], implicit a5 : (Arb[A5]) => Arbitrary[A5], implicit a6 : (Arb[A6]) => Arbitrary[A6]) : Unit

def checkProperties(prms : Params) : Map[String, Stats]
Tests all properties with the given testing parameters, and returns the test results.

def checkProperties(prms : Params, propCallback : Function4, testCallback : Function2) : Map[String, Stats]
Tests all properties with the given testing parameters, and returns the test results. f is a function which is called each time a property is evaluted. g is a function called each time a property has been fully tested.

def checkProperties : Map[String, Stats]
Tests all properties with default testing parameters, and returns the test results. The results are also printed on the console during testing.

def testCases : scala.List[TestCase]
Returns all properties as SUnit.TestCase instances, which can added to a SUnit.TestSuite.

def allProperties : Prop
Returns all properties combined into a single property, that holds when all properties hold