So I am writing some Scala tests for some Java code (I am very new at both of them). What I am trying to do is instead of calling .create on the Configuration class, I want to call create on the conf mock object. How can I go about doing this?
When I try to call .create on a mock of the Configuration class, I get an error since (I think) .create is a static method from a custom abstract Configuration java class
Scala test code:
var conf: Configuration = mock[Configuration]
when(Configuration.create("var1","var2", "var3")).thenReturn(testConfiguration)
Thanks!