How to populate java.util.HashMap on the fly from Scala code?

Viewed 17332

I am unit testing java code from ScalaTest and would like to populate a java.util.HashMap within the same statement it gets declared. Is it possible to do this in Scala?

5 Answers
Related