build test code against scalatest
convert java collection to scala