The official scalacheck documentation gives the following example:
property("stringLength") = Prop.forAll { s: String =>
val len = s.length
(s+s).length == len+len
}
I read that this can also be written as:
val stringLength = Prop.forAll { s: String =>
val len = s.length
(s+s).length == len+len
}
How can I run the second form of test code? When I execute sbt test
, nothing happens with the second version.