I am using mockito and trying to mock a scala object.
object Sample { }
//test
class SomeTest extends Specification with ScalaTest with Mockito {
"mocking should succeed" in {
val mockedSample = mock[Sample]
}
}
Give me 2 compilation errors.
error: Not found type Sample
error: could not find implicit value for parameter m: scala.reflect.ClassManifest[<error>]
If I change Sample from object to class it works. Is is possible to mock scala objects with mockito? if yes how?