Closed
Description
Hi,
def matchOptions(res0: Float, res1: Float) {
val someValue: Option[Double] = Some(20.0)
val value = someValue match {
case Some(v) ⇒ v
case None ⇒ 0.0
}
value should be(res0)
val noValue: Option[Double] = None
val value1 = noValue match {
case Some(v) ⇒ v
case None ⇒ 0.0
}
value1 should be(res1)
}
The above test in the options exercise throws an error because the test is comparing a Float to a Double value1 should be(res1)
and most persons input their answers as Double.
I could put in a pull request.