Package mockit
Class FullVerificationsTest
java.lang.Object
mockit.FullVerificationsTest
The Class FullVerificationsTest.
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic class
The Class Dependency. -
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoid
Verify all invocations.void
Verify all invocations except those already verified in A previous verification block.void
Verify all invocations with extra verification.void
Verify all invocations with invocation count more than actual.void
Verify all invocations with invocation count one less than actual.void
Verify all invocations with invocation count two less than actual.void
Verify all invocations with one missing.void
Verify all invocations with some of them recorded.void
Verify all invocations with those recorded as expected to occur verified implicitly.void
Verify invocation that is allowed to happen any number of times and happens once.void
Verify no invocations occurred on mocked dependency with one having occurred.void
Verify no invocations on mocked dependency beyond those recorded as expected.void
Verify no invocations on mocked dependency beyond those recorded as expected with one having occurred.void
Verify no unverified invocations when first invocation of method is but second one is not.void
Verify no unverified invocations when second invocation of method is but first one is not.void
Verify recorded invocation that is allowed to happen any no of times and does not happen.void
Verify recorded invocation that should happen but does not.void
Verify unrecorded invocation that is allowed to happen any no of times and does not happen.void
Verify unrecorded invocation that should happen but does not.void
Verify unrecorded invocation that should not happen but does.void
Verify unrecorded invocation that was expected to not happen.
-
Field Details
-
thrown
public final org.junit.rules.ExpectedException thrownThe thrown.
-
-
Constructor Details
-
FullVerificationsTest
public FullVerificationsTest()
-
-
Method Details
-
verifyAllInvocations
public void verifyAllInvocations()Verify all invocations. -
verifyAllInvocationsWithSomeOfThemRecorded
public void verifyAllInvocationsWithSomeOfThemRecorded()Verify all invocations with some of them recorded. -
verifyAllInvocationsWithThoseRecordedAsExpectedToOccurVerifiedImplicitly
public void verifyAllInvocationsWithThoseRecordedAsExpectedToOccurVerifiedImplicitly()Verify all invocations with those recorded as expected to occur verified implicitly. -
verifyAllInvocationsExceptThoseAlreadyVerifiedInAPreviousVerificationBlock
public void verifyAllInvocationsExceptThoseAlreadyVerifiedInAPreviousVerificationBlock()Verify all invocations except those already verified in A previous verification block. -
verifyAllInvocationsWithOneMissing
public void verifyAllInvocationsWithOneMissing()Verify all invocations with one missing. -
verifyUnrecordedInvocationThatWasExpectedToNotHappen
public void verifyUnrecordedInvocationThatWasExpectedToNotHappen()Verify unrecorded invocation that was expected to not happen. -
verifyUnrecordedInvocationThatShouldNotHappenButDoes
public void verifyUnrecordedInvocationThatShouldNotHappenButDoes()Verify unrecorded invocation that should not happen but does. -
verifyInvocationThatIsAllowedToHappenAnyNumberOfTimesAndHappensOnce
public void verifyInvocationThatIsAllowedToHappenAnyNumberOfTimesAndHappensOnce()Verify invocation that is allowed to happen any number of times and happens once. -
verifyRecordedInvocationThatIsAllowedToHappenAnyNoOfTimesAndDoesNotHappen
public void verifyRecordedInvocationThatIsAllowedToHappenAnyNoOfTimesAndDoesNotHappen()Verify recorded invocation that is allowed to happen any no of times and does not happen. -
verifyUnrecordedInvocationThatIsAllowedToHappenAnyNoOfTimesAndDoesNotHappen
public void verifyUnrecordedInvocationThatIsAllowedToHappenAnyNoOfTimesAndDoesNotHappen()Verify unrecorded invocation that is allowed to happen any no of times and does not happen. -
verifyUnrecordedInvocationThatShouldHappenButDoesNot
public void verifyUnrecordedInvocationThatShouldHappenButDoesNot()Verify unrecorded invocation that should happen but does not. -
verifyRecordedInvocationThatShouldHappenButDoesNot
public void verifyRecordedInvocationThatShouldHappenButDoesNot()Verify recorded invocation that should happen but does not. -
verifyAllInvocationsWithExtraVerification
public void verifyAllInvocationsWithExtraVerification()Verify all invocations with extra verification. -
verifyAllInvocationsWithInvocationCountOneLessThanActual
public void verifyAllInvocationsWithInvocationCountOneLessThanActual()Verify all invocations with invocation count one less than actual. -
verifyAllInvocationsWithInvocationCountTwoLessThanActual
public void verifyAllInvocationsWithInvocationCountTwoLessThanActual()Verify all invocations with invocation count two less than actual. -
verifyAllInvocationsWithInvocationCountMoreThanActual
public void verifyAllInvocationsWithInvocationCountMoreThanActual()Verify all invocations with invocation count more than actual. -
verifyNoInvocationsOccurredOnMockedDependencyWithOneHavingOccurred
public void verifyNoInvocationsOccurredOnMockedDependencyWithOneHavingOccurred()Verify no invocations occurred on mocked dependency with one having occurred. -
verifyNoInvocationsOnMockedDependencyBeyondThoseRecordedAsExpected
public void verifyNoInvocationsOnMockedDependencyBeyondThoseRecordedAsExpected()Verify no invocations on mocked dependency beyond those recorded as expected. -
verifyNoInvocationsOnMockedDependencyBeyondThoseRecordedAsExpectedWithOneHavingOccurred
public void verifyNoInvocationsOnMockedDependencyBeyondThoseRecordedAsExpectedWithOneHavingOccurred()Verify no invocations on mocked dependency beyond those recorded as expected with one having occurred. -
verifyNoUnverifiedInvocationsWhenFirstInvocationOfMethodIsButSecondOneIsNot
public void verifyNoUnverifiedInvocationsWhenFirstInvocationOfMethodIsButSecondOneIsNot()Verify no unverified invocations when first invocation of method is but second one is not. -
verifyNoUnverifiedInvocationsWhenSecondInvocationOfMethodIsButFirstOneIsNot
public void verifyNoUnverifiedInvocationsWhenSecondInvocationOfMethodIsButFirstOneIsNot()Verify no unverified invocations when second invocation of method is but first one is not.
-