Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // import
- import static org.powermock.api.support.membermodification.MemberMatcher.method;
- import static org.powermock.api.support.membermodification.MemberModifier.stub;
- // annotation
- @RunWith(PowerMockRunner.class)
- @PrepareForTest({ $XxxController.class, $XxxServiceImpl.class })
- //mock
- stub(method( $XxxController.class , " $methodName ")).toReturn( $RETURN_VALUE );
Add Comment
Please, Sign In to add comment