scalacheck
scalacheck copied to clipboard
Expose Gens for BigDecimal with provided scale
In #670, @non introduced two methods that return Gens with a provided scale:
def chooseBigDecimalScale(minScale: Int): Choose[BigDecimal]
def chooseJavaBigDecimalScale(minScale: Int): Choose[JavaDecimal]
Both of them are private. We should consider making them public.
Also documntation states:
The implicit instance fixes this value, but since users may want to use other scales we expose this method as well.
but method is not exposed.
As a workaround I think .setScale on a generated BigDecimal should do the trick.