--
You received this message because you are subscribed to the Google Groups "scalacheck" group.
To unsubscribe from this group and stop receiving emails from it, send an email to scalacheck+...@googlegroups.com.
To post to this group, send email to scala...@googlegroups.com.
Visit this group at http://groups.google.com/group/scalacheck.
I'm tried to override the mainRunner of Properties trait, but the parameters are not changed as expected. What's the correct way to achieve this?
import org.scalacheck.Prop.forAll
import org.scalacheck.Test
import org.scalacheck.{Gen, Properties}
import org.scalatest.Matchers
class CoordinateTruncProp extends Properties("CoordinateTruncProperties") with Matchers {
override def mainRunner(args: Array[String]): Int = {
val res = Test.checkProperties(Test.Parameters.default.withMinSize(200).withMaxSize(1000).withMinSuccessfulTests(200), this)
val failed = res.filter(!_._2.passed).size
failed
}
property("CoordinateTrunc") =
forAll(Gen.choose(-400.0, 400.0)) { (coord) =>
coord - truncateDoubles.truncate(coord) < 0.1
}
...
}