Replace expect by expectResult, as expect has been deprecated in ScalaTest