spring WrongTypeOfReturnValue code example
Example: org.mockito.exceptions.misusing.WrongTypeOfReturnValue
//use
doReturn(fooBar).when(bar).getFoo()
//instead of
when(bar.getFoo()).thenReturn(fooBar)
//use
doReturn(fooBar).when(bar).getFoo()
//instead of
when(bar.getFoo()).thenReturn(fooBar)