Comparing doubles sucks :). Here is how ScalaTest helps you with it:
import org.scalatest._
class MyTest extends FlatSpec with ShouldMatchers {
...
100.0 should be (100.0 plusOrMinus 1e-9)
...
}
An alternative for plusOrMinus
is +-
method.