add scalatest and scalacheck unit test case