I'm pretty new to Scala and I'd like to know if there's some way to create a dummy Future
object to simulate isCompleted
to false
. I need this for testing purposes.
Currently what I'm using to have a dummy Future[Int]
is this:
Future({
while (true) {}
1
})
which is very ugly.
Aucun commentaire:
Enregistrer un commentaire