public VerificationCollector assertLazily() { mockingProgress().setVerificationStrategy(new VerificationStrategy() { public VerificationMode maybeVerifyLazily(VerificationMode mode) { return new VerificationWrapper(mode); } }); return this; }
public void reset() { stubbingInProgress = null; verificationMode = null; getArgumentMatcherStorage().reset(); }
/** * char argument that does not match the given argument matcher. * <p> * See examples in javadoc for {@link AdditionalMatchers} class * * @param first * placeholder for the argument matcher. * @return <code>0</code>. */ public static char not(char first) { mockingProgress().getArgumentMatcherStorage().reportNot(); return 0; }
/** * int argument that matches any of the given argument matchers. * <p> * See examples in javadoc for {@link AdditionalMatchers} class * * @param first * placeholder for the first argument matcher. * @param second * placeholder for the second argument matcher. * @return <code>0</code>. */ public static int or(int first, int second) { mockingProgress().getArgumentMatcherStorage().reportOr(); return 0; }
private static void reportMatcher(ArgumentMatcher<?> matcher) { mockingProgress().getArgumentMatcherStorage().reportMatcher(matcher); } }
/** * int argument that matches both given argument matchers. * <p> * See examples in javadoc for {@link AdditionalMatchers} class * * @param first * placeholder for the first argument matcher. * @param second * placeholder for the second argument matcher. * @return <code>0</code>. */ public static int and(int first, int second) { mockingProgress().getArgumentMatcherStorage().reportAnd(); return 0; }
/** * short argument that does not match the given argument matcher. * <p> * See examples in javadoc for {@link AdditionalMatchers} class * * @param first * placeholder for the argument matcher. * @return <code>0</code>. */ public static short not(short first) { mockingProgress().getArgumentMatcherStorage().reportNot(); return 0; }
/** * byte argument that matches any of the given argument matchers. * <p> * See examples in javadoc for {@link AdditionalMatchers} class * * @param first * placeholder for the first argument matcher. * @param second * placeholder for the second argument matcher. * @return <code>0</code>. */ public static byte or(byte first, byte second) { mockingProgress().getArgumentMatcherStorage().reportOr(); return 0; }
private static void reportMatcher(ArgumentMatcher<?> matcher) { mockingProgress().getArgumentMatcherStorage().reportMatcher(matcher); } }
/** * boolean argument that matches both given matchers. * <p> * See examples in javadoc for {@link AdditionalMatchers} class * * @param first * placeholder for the first argument matcher. * @param second * placeholder for the second argument matcher. * @return <code>false</code>. */ public static boolean and(boolean first, boolean second) { mockingProgress().getArgumentMatcherStorage().reportAnd(); return false; }
/** * long argument that does not match the given argument matcher. * <p> * See examples in javadoc for {@link AdditionalMatchers} class * * @param first * placeholder for the argument matcher. * @return <code>0</code>. */ public static long not(long first) { mockingProgress().getArgumentMatcherStorage().reportNot(); return 0; }
/** * long argument that matches any of the given argument matchers. * <p> * See examples in javadoc for {@link AdditionalMatchers} class * * @param first * placeholder for the first argument matcher. * @param second * placeholder for the second argument matcher. * @return <code>0</code>. */ public static long or(long first, long second) { mockingProgress().getArgumentMatcherStorage().reportOr(); return 0; }
/** * float argument that does not match the given argument matcher. * <p> * See examples in javadoc for {@link AdditionalMatchers} class * * @param first * placeholder for the argument matcher. * @return <code>0</code>. */ public static float not(float first) { mockingProgress().getArgumentMatcherStorage().reportNot(); return 0; }
/** * float argument that matches any of the given argument matchers. * <p> * See examples in javadoc for {@link AdditionalMatchers} class * * @param first * placeholder for the first argument matcher. * @param second * placeholder for the second argument matcher. * @return <code>0</code>. */ public static float or(float first, float second) { mockingProgress().getArgumentMatcherStorage().reportOr(); return 0; }
/** * byte argument that does not match the given argument matcher. * <p> * See examples in javadoc for {@link AdditionalMatchers} class * * @param first * placeholder for the argument matcher. * @return <code>0</code>. */ public static byte not(byte first) { mockingProgress().getArgumentMatcherStorage().reportNot(); return 0; }
/** * boolean argument that matches any of the given argument matchers. * <p> * See examples in javadoc for {@link AdditionalMatchers} class * * @param first * placeholder for the first argument matcher. * @param second * placeholder for the second argument matcher. * @return <code>false</code>. */ public static boolean or(boolean first, boolean second) { mockingProgress().getArgumentMatcherStorage().reportOr(); return false; }
/** * boolean argument that does not match the given argument matcher. * <p> * See examples in javadoc for {@link AdditionalMatchers} class * * @param first * placeholder for the argument matcher. * @return <code>false</code>. */ public static boolean not(boolean first) { mockingProgress().getArgumentMatcherStorage().reportNot(); return false; }
/** * int argument that does not match the given argument matcher. * <p> * See examples in javadoc for {@link AdditionalMatchers} class * * @param first * placeholder for the argument matcher. * @return <code>0</code>. */ public static int not(int first) { mockingProgress().getArgumentMatcherStorage().reportNot(); return 0; }
/** * double argument that does not match the given argument matcher. * <p> * See examples in javadoc for {@link AdditionalMatchers} class * * @param first * placeholder for the argument matcher. * @return <code>0</code>. */ public static double not(double first) { mockingProgress().getArgumentMatcherStorage().reportNot(); return 0; }
/** * Object argument that does not match the given argument matcher. * <p> * See examples in javadoc for {@link AdditionalMatchers} class * * @param <T> * the type of the object, it is passed through to prevent casts. * @param first * placeholder for the argument matcher. * @return <code>null</code>. */ public static <T> T not(T first) { mockingProgress().getArgumentMatcherStorage().reportNot(); return null; }