score:0

Yours is really a ScalaCheck question, but one way to avoid the whole question is to use ScalaTest's PropertyChecks syntax instead of ScalaCheck's (which is supported in ScalaTest by Checkers):

import org.scalatest.prop.Checkers._

check { (n: Int) =>
  n > 1 ==> n / 2 > 0
}

becomes:

import org.scalatest.MustMatchers._
import org.scalatest.prop.PropertyChecks._

forAll { (n: Int) =>
  whenever (n > 1) {
    n / 2 must be > 0
  }
}

Related Query

More Query from same tag