Home
last modified time | relevance | path

Searched refs:isMock (Results 1 – 25 of 27) sorted by relevance

12

/external/mockito/src/test/java/org/mockito/internal/framework/
DDefaultMockitoFrameworkTest.java131 assertTrue(mockingDetails(mock).isMock()); in clearing_all_mocks_is_safe_regardless_of_mock_maker_type()
142 assertTrue(mockingDetails(list1).isMock()); in clears_all_mocks()
144 assertTrue(mockingDetails(list2).isMock()); in clears_all_mocks()
150 assertFalse(mockingDetails(list1).isMock()); in clears_all_mocks()
151 assertFalse(mockingDetails(list2).isMock()); in clears_all_mocks()
161 assertTrue(mockingDetails(list1).isMock()); in clears_mock()
163 assertTrue(mockingDetails(list2).isMock()); in clears_mock()
169 assertFalse(mockingDetails(list1).isMock()); in clears_mock()
170 assertTrue(mockingDetails(list2).isMock()); in clears_mock()
/external/mockito/src/test/java/org/mockito/internal/util/
DDefaultMockingDetailsTest.java52 assertTrue(mockingDetails(gork).isMock()); in should_know_spy()
53 assertTrue(mockingDetails(spy( new Gork())).isMock()); in should_know_spy()
54 assertTrue(mockingDetails(spy(Gork.class)).isMock()); in should_know_spy()
55 …ckingDetails(mock(Gork.class, withSettings().defaultAnswer(Mockito.CALLS_REAL_METHODS))).isMock()); in should_know_spy()
60 assertTrue(mockingDetails(foo).isMock()); in should_know_mock()
61 assertTrue(mockingDetails(mock(Foo.class)).isMock()); in should_know_mock()
69 assertFalse(mockingDetails("non mock").isMock()); in should_handle_non_mocks()
72 assertFalse(mockingDetails(null).isMock()); in should_handle_non_mocks()
77 assertEquals(true, mockingDetails(gork).isMock()); in should_check_that_a_spy_is_also_a_mock()
DMockUtilTest.java49 assertFalse(MockUtil.isMock("i mock a mock")); in should_validate_mock()
50 assertTrue(MockUtil.isMock(Mockito.mock(List.class))); in should_validate_mock()
/external/mockito/src/test/java/org/mockitousage/annotation/
DSpyAnnotationInitializedInBaseClassTest.java18 import static org.mockito.internal.util.MockUtil.isMock;
40 assertTrue(MockUtil.isMock(subClass.list)); in shouldInitSpiesInBaseClass()
64 assertTrue(isMock(spyInSubclass)); in shouldInitSpiesInHierarchy()
65 assertTrue(isMock(spyInBaseclass)); in shouldInitSpiesInHierarchy()
DMockInjectionUsingSetterOrPropertyTest.java70 assertTrue(MockUtil.isMock(initializedSpy)); in should_inject_mocks_in_spy()
77 assertTrue(MockUtil.isMock(notInitializedSpy)); in should_initialize_spy_if_null_and_inject_mocks()
DMockInjectionUsingConstructorTest.java86 assertFalse(MockUtil.isMock(articleManager)); in objects_created_with_constructor_initialization_can_be_spied()
87 assertTrue(MockUtil.isMock(spiedArticleManager)); in objects_created_with_constructor_initialization_can_be_spied()
DSpyInjectionTest.java30 MockUtil.isMock(hasSpy.spy); in shouldDoStuff()
DMockInjectionUsingConstructorIssue421Test.java42 assertThat(MockUtil.isMock(calculator)).isTrue(); in checkIfMockIsInjected()
/external/mockito/src/main/java/org/mockito/internal/util/
DDefaultMockingDetails.java31 public boolean isMock(){ in isMock() method in DefaultMockingDetails
32 return MockUtil.isMock(toInspect); in isMock()
84 } else if (!isMock()) { in assertGoodMock()
DMockUtil.java58 if (isMock(mock)) { in getMockHandler()
70 … return isMock(mock) && getMockSettings(mock).getDefaultAnswer() == Mockito.CALLS_REAL_METHODS; in isSpy()
73 public static boolean isMock(Object mock) { in isMock() method in MockUtil
/external/mockito/src/test/java/org/mockito/internal/stubbing/defaultanswers/
DReturnsMocksTest.java30 assertTrue(MockUtil.isMock(interfaceMock)); in should_return_mock_value_for_interface()
36 assertTrue(MockUtil.isMock(classMock)); in should_return_mock_value_for_class()
/external/grpc-grpc-java/core/src/test/java/io/grpc/
DForwardingTestUtil.java80 assertTrue(mockingDetails(mockDelegate).isMock()); in testMethodsForwarded()
81 assertFalse(mockingDetails(forwarder).isMock()); in testMethodsForwarded()
/external/mockito/src/main/java/org/mockito/internal/stubbing/
DStubberImpl.java23 import static org.mockito.internal.util.MockUtil.isMock;
42 if (!isMock(mock)) { in when()
/external/mockito/src/main/java/org/mockito/internal/creation/bytebuddy/
DMockMethodAdvice.java117 public boolean isMock(Object instance) { in isMock() method in MockMethodAdvice
125 return selfCallInfo.checkSuperCall(instance) && isMock(instance); in isMocked()
283 return dispatcher != null && dispatcher.isMock(self); in enter()
304 return dispatcher != null && dispatcher.isMock(self); in enter()
DMockMethodDispatcher.java30 public abstract boolean isMock(Object instance); in isMock() method in MockMethodDispatcher
/external/mockito/src/main/java/org/mockito/internal/
DMockitoCore.java51 import static org.mockito.internal.util.MockUtil.isMock;
91 if (!mockingDetails.isMock()) { in verify()
166 if (!isMock(mock)) { in inOrder()
/external/mockito/src/main/java/org/mockito/
DMockingDetails.java30 boolean isMock(); in isMock() method
/external/mockito/src/main/java/org/mockito/internal/util/collections/
DHashCodeAndEqualsMockWrapper.java60 …"mockInstance=" + (MockUtil.isMock(mockInstance) ? MockUtil.getMockName(mockInstance) : typeInstan… in toString()
/external/dexmaker/dexmaker-mockito-inline/src/main/java/com/android/dx/mockito/inline/
DMockMethodAdvice.java212 public boolean isMock(Object instance) { in isMock() method in MockMethodAdvice
228 return selfCallInfo.shouldMockMethod(instance) && isMock(instance); in isMocked()
/external/mockito/src/test/java/org/mockito/internal/junit/
DJUnitRuleTest.java26 assertTrue(mockingDetails(mock).isMock()); in injects_into_test_case()
/external/mockito/src/main/java/org/mockito/internal/stubbing/answers/
DThrowsException.java40 if (MockUtil.isMock(throwable)) { in answer()
/external/mockito/src/main/java/org/mockito/internal/configuration/injection/
DSpyOnInjectedFieldsHandler.java38 if (MockUtil.isMock(instance)) { in processInjection()
/external/mockito/src/main/java/org/mockito/internal/configuration/injection/scanner/
DMockScanner.java83 return MockUtil.isMock(instance) in isMockOrSpy()
/external/mockito/src/main/java/org/mockito/internal/listeners/
DVerificationStartedNotifier.java45 if (!mockingDetails.isMock()) { in setMock()
/external/dexmaker/dexmaker-mockito-inline-dispatcher/src/main/java/com/android/dx/mockito/inline/
DMockMethodDispatcher.java88 public boolean isMock(Object instance) { in isMock() method in MockMethodDispatcher

12