Home
last modified time | relevance | path

Searched refs:mocks (Results 1 – 25 of 46) sorted by relevance

12

/external/mockito/src/org/mockito/internal/util/collections/
DHashCodeAndEqualsSafeSet.java115 public boolean removeAll(Collection<?> mocks) { in removeAll() argument
116 return backingHashSet.removeAll(asWrappedMocks(mocks)); in removeAll()
119 public boolean containsAll(Collection<?> mocks) { in containsAll() argument
120 return backingHashSet.containsAll(asWrappedMocks(mocks)); in containsAll()
123 public boolean addAll(Collection<?> mocks) { in addAll() argument
124 return backingHashSet.addAll(asWrappedMocks(mocks)); in addAll()
127 public boolean retainAll(Collection<?> mocks) { in retainAll() argument
128 return backingHashSet.retainAll(asWrappedMocks(mocks)); in retainAll()
131 private HashSet<HashCodeAndEqualsMockWrapper> asWrappedMocks(Collection<?> mocks) { in asWrappedMocks() argument
132 Checks.checkNotNull(mocks, "Passed collection should notify() be null"); in asWrappedMocks()
[all …]
DSets.java15 public static Set<Object> newMockSafeHashSet(Iterable<Object> mocks) { in newMockSafeHashSet() argument
16 return HashCodeAndEqualsSafeSet.of(mocks); in newMockSafeHashSet()
19 public static Set<Object> newMockSafeHashSet(Object... mocks) { in newMockSafeHashSet() argument
20 return HashCodeAndEqualsSafeSet.of(mocks); in newMockSafeHashSet()
/external/mockito/src/org/mockito/internal/
DMockitoCore.java89 public <T> void reset(T ... mocks) { in reset() argument
94 for (T m : mocks) { in reset()
99 public void verifyNoMoreInteractions(Object... mocks) { in verifyNoMoreInteractions() argument
100 assertMocksNotEmpty(mocks); in verifyNoMoreInteractions()
102 for (Object mock : mocks) { in verifyNoMoreInteractions()
116 public void verifyNoMoreInteractionsInOrder(List<Object> mocks, InOrderContext inOrderContext) { in verifyNoMoreInteractionsInOrder() argument
119 …cationDataInOrder data = new VerificationDataInOrderImpl(inOrderContext, finder.find(mocks), null); in verifyNoMoreInteractionsInOrder()
123 private void assertMocksNotEmpty(Object[] mocks) { in assertMocksNotEmpty() argument
124 if (mocks == null || mocks.length == 0) { in assertMocksNotEmpty()
129 public InOrder inOrder(Object... mocks) { in inOrder() argument
[all …]
/external/mockito/src/org/mockito/
DMockito.java1530 public static <T> void reset(T ... mocks) { in reset() argument
1531 MOCKITO_CORE.reset(mocks); in reset()
1575 public static void verifyNoMoreInteractions(Object... mocks) { in verifyNoMoreInteractions() argument
1576 MOCKITO_CORE.verifyNoMoreInteractions(mocks); in verifyNoMoreInteractions()
1594 public static void verifyZeroInteractions(Object... mocks) { in verifyZeroInteractions() argument
1595 MOCKITO_CORE.verifyNoMoreInteractions(mocks); in verifyZeroInteractions()
1854 public static InOrder inOrder(Object... mocks) { in inOrder() argument
1855 return MOCKITO_CORE.inOrder(mocks); in inOrder()
1921 public static Object[] ignoreStubs(Object... mocks) { in ignoreStubs() argument
1922 return MOCKITO_CORE.ignoreStubs(mocks); in ignoreStubs()
DMockitoDebugger.java11 String printInvocations(Object ... mocks); in printInvocations() argument
/external/mockito/src/org/mockito/internal/configuration/injection/
DMockInjection.java56 private Set<Object> mocks = newMockSafeHashSet(); field in MockInjection.OngoingMockInjection
70 public OngoingMockInjection withMocks(Set<Object> mocks) { in withMocks() argument
71 this.mocks.addAll(checkNotNull(mocks, "mocks")); in withMocks()
92 injectionStrategies.process(field, fieldOwner, mocks); in apply()
93 postInjectionStrategies.process(field, fieldOwner, mocks); in apply()
DPropertyAndSetterInjection.java101 …private boolean injectMockCandidates(Class<?> awaitingInjectionClazz, Set<Object> mocks, Object in… in injectMockCandidates() argument
105 …injectionOccurred |= injectMockCandidatesOnFields(mocks, instance, injectionOccurred, orderedInsta… in injectMockCandidates()
107 …injectionOccurred |= injectMockCandidatesOnFields(mocks, instance, injectionOccurred, orderedInsta… in injectMockCandidates()
111 …private boolean injectMockCandidatesOnFields(Set<Object> mocks, Object instance, boolean injection… in injectMockCandidatesOnFields() argument
114 … Object injected = mockCandidateFilter.filterCandidate(mocks, field, instance).thenInject(); in injectMockCandidatesOnFields()
117 mocks.remove(injected); in injectMockCandidatesOnFields()
/external/mockito/src/org/mockito/internal/configuration/injection/scanner/
DMockScanner.java46 public void addPreparedMocks(Set<Object> mocks) { in addPreparedMocks() argument
47 mocks.addAll(scan()); in addPreparedMocks()
56 Set<Object> mocks = newMockSafeHashSet(); in scan() local
63 mocks.add(mockInstance); in scan()
66 return mocks; in scan()
/external/mockito/src/org/mockito/internal/configuration/injection/filter/
DNameBasedCandidateFilter.java22 …public OngoingInjecter filterCandidate(Collection<Object> mocks, Field field, Object fieldInstance… in filterCandidate() argument
24 if(mocks.size() > 1) { in filterCandidate()
25 for (Object mock : mocks) { in filterCandidate()
32 return next.filterCandidate(mocks, field, fieldInstance); in filterCandidate()
DFinalMockCandidateFilter.java23 …public OngoingInjecter filterCandidate(final Collection<Object> mocks, final Field field, final Ob… in filterCandidate() argument
24 if(mocks.size() == 1) { in filterCandidate()
25 final Object matchingMock = mocks.iterator().next(); in filterCandidate()
DTypeBasedCandidateFilter.java20 …public OngoingInjecter filterCandidate(Collection<Object> mocks, Field field, Object fieldInstance… in filterCandidate() argument
22 for (Object mock : mocks) { in filterCandidate()
DMockCandidateFilter.java13 Collection<Object> mocks, in filterCandidate() argument
/external/easymock/src/org/easymock/
DEasyMock.java1545 public static void replay(Object... mocks) { in replay() argument
1546 for (Object mock : mocks) { in replay()
1558 public static void reset(Object... mocks) { in reset() argument
1559 for (Object mock : mocks) { in reset()
1572 public static void resetToNice(Object... mocks) { in resetToNice() argument
1573 for (Object mock : mocks) { in resetToNice()
1586 public static void resetToDefault(Object... mocks) { in resetToDefault() argument
1587 for (Object mock : mocks) { in resetToDefault()
1600 public static void resetToStrict(Object... mocks) { in resetToStrict() argument
1601 for (Object mock : mocks) { in resetToStrict()
[all …]
/external/mockito/src/org/mockito/internal/debugging/
DMockitoDebuggerImpl.java21 public String printInvocations(Object ... mocks) { in printInvocations() argument
23 List<Invocation> invocations = allInvocationsFinder.find(asList(mocks)); in printInvocations()
35 invocations = unusedStubsFinder.find(asList(mocks)); in printInvocations()
/external/mockito/src/org/mockito/internal/configuration/
DInjectingAnnotationEngine.java92 Set<Object> mocks = newMockSafeHashSet(); in injectMocks() local
96 new MockScanner(testClassInstance, clazz).addPreparedMocks(mocks); in injectMocks()
100 … new DefaultInjectionEngine().injectMocksOnFields(mockDependentFields, mocks, testClassInstance); in injectMocks()
DDefaultInjectionEngine.java19 …public void injectMocksOnFields(Set<Field> needingInjection, Set<Object> mocks, Object testClassIn… in injectMocksOnFields() argument
21 .withMocks(mocks) in injectMocksOnFields()
/external/mockito/src/org/mockito/internal/invocation/finder/
DVerifiableInvocationsFinder.java18 public List<Invocation> find(List<?> mocks) { in find() argument
19 List<Invocation> invocations = new AllInvocationsFinder().find(mocks); in find()
DAllInvocationsFinder.java22 public List<Invocation> find(List<?> mocks) { in find() argument
24 for (Object mock : mocks) { in find()
/external/android-mock/src/com/google/android/testing/mocking/
DAndroidMock.java2459 public static void replay(Object... mocks) { in replay() argument
2460 for (Object mockObject : mocks) { in replay()
2475 public static void reset(Object... mocks) { in reset() argument
2476 for (Object mockObject : mocks) { in reset()
2492 public static void resetToNice(Object... mocks) { in resetToNice() argument
2493 for (Object mockObject : mocks) { in resetToNice()
2509 public static void resetToDefault(Object... mocks) { in resetToDefault() argument
2510 for (Object mockObject : mocks) { in resetToDefault()
2526 public static void resetToStrict(Object... mocks) { in resetToStrict() argument
2527 for (Object mockObject : mocks) { in resetToStrict()
[all …]
DAndroidFrameworkMockGenerator.java93 List<GeneratedClassFile> mocks = new ArrayList<GeneratedClassFile>(); in createMocksForClass() local
94 mocks.addAll(mockGenerator.createMocksForClass(clazz, version)); in createMocksForClass()
95 return mocks; in createMocksForClass()
/external/android-mock/tests/com/google/android/testing/mocking/
DAndroidFrameworkMockGeneratorTest.java145 List<GeneratedClassFile> mocks = mockGenerator.getMocksForClass(Vector.class); in testGetMocksForClass() local
160 assertEquals(expectedClassNames.length, mocks.size()); in testGetMocksForClass()
161 for (int i = 0; i < mocks.size(); ++i) { in testGetMocksForClass()
162 assertEquals(expectedClassNames[i], mocks.get(i).getClassName()); in testGetMocksForClass()
/external/mockito/src/org/mockito/internal/invocation/
DUnusedStubsFinder.java22 public List<Invocation> find(List<?> mocks) { in find() argument
24 for (Object mock : mocks) { in find()
/external/chromium_org/third_party/ocmock/
DChanges.txt36 * Added feature to explicitly reject methods on nice mocks (thanks to Heath Borders)
77 * Partial mocks are now deallocated as they should
78 * Fixed problems that occured when using mocks as arguments
119 * Partial mocks now work on object reference and self (thanks to Mike Mangino)
124 * Added partial mocks (calls to the original object reference cannot be mocked)
203 * Added nice mocks, i.e. mocks that don't raise on unknown methods (Mark Thomas)
/external/chromium-trace/trace-viewer/third_party/gl-matrix/
DGemfile.lock24 rspec-mocks (~> 2.11.0)
28 rspec-mocks (2.11.2)
/external/littlemock/src/com/google/testing/littlemock/
DLittleMock.java206 public static void verifyZeroInteractions(Object... mocks) {
208 for (Object mock : mocks) {
215 public static void verifyNoMoreInteractions(Object... mocks) {
217 for (Object mock : mocks) {
469 public static void reset(Object... mocks) {
470 for (Object mock : mocks) {
1348 public static InOrder inOrder(Object... mocks) {

12