Home
last modified time | relevance | path

Searched refs:typeToMock (Results 1 – 6 of 6) sorted by relevance

/external/mockito/src/org/mockito/internal/creation/
DMockSettingsImpl.java138 return typeToMock; in getTypeToMock()
141 public MockCreationSettings<T> confirm(Class<T> typeToMock) { in confirm() argument
142 return validatedSettings(typeToMock, this); in confirm()
145 …private static <T> CreationSettings<T> validatedSettings(Class<T> typeToMock, CreationSettings<T> … in validatedSettings() argument
148 validator.validateType(typeToMock); in validatedSettings()
149 validator.validateExtraInterfaces(typeToMock, source.getExtraInterfaces()); in validatedSettings()
150 validator.validateMockedType(typeToMock, source.getSpiedInstance()); in validatedSettings()
155 validator.validateSerializable(typeToMock, source.isSerializable()); in validatedSettings()
158 settings.setMockName(new MockNameImpl(source.getName(), typeToMock)); in validatedSettings()
159 settings.setTypeToMock(typeToMock); in validatedSettings()
DAcrossJVMSerializationFeature.java184 private Class typeToMock; field in AcrossJVMSerializationFeature.AcrossJVMMockSerializationProxy
206 this.typeToMock = mockSettings.getTypeToMock(); in AcrossJVMMockSerializationProxy()
221 …tInputStream objectInputStream = new MockitoMockObjectInputStream(bis, typeToMock, extraInterfaces… in readResolve()
231 …"Mockito mock cannot be deserialized to a mock of '" + typeToMock.getCanonicalName() + "'. The err… in readResolve()
266 private Class typeToMock; field in AcrossJVMSerializationFeature.MockitoMockObjectInputStream
269 …public MockitoMockObjectInputStream(InputStream in, Class typeToMock, Set<Class> extraInterfaces) … in MockitoMockObjectInputStream() argument
271 this.typeToMock = typeToMock; in MockitoMockObjectInputStream()
298 ClassImposterizer.INSTANCE.setConstructorsAccessible(typeToMock, true); in resolveClass()
300 typeToMock, in resolveClass()
/external/mockito/src/org/mockito/internal/creation/settings/
DCreationSettings.java24 protected Class<T> typeToMock; field in CreationSettings
38 this.typeToMock = copy.typeToMock; in CreationSettings()
50 return typeToMock; in getTypeToMock()
53 public CreationSettings<T> setTypeToMock(Class<T> typeToMock) { in setTypeToMock() argument
54 this.typeToMock = typeToMock; in setTypeToMock()
/external/dexmaker/src/mockito/java/com/google/dexmaker/mockito/
DDexmakerMockMaker.java38 Class<T> typeToMock = settings.getTypeToMock(); in createMock() local
43 if (typeToMock.isInterface()) { in createMock()
46 classesToMock[0] = typeToMock; in createMock()
57 Class<? extends T> proxyClass = ProxyBuilder.forClass(typeToMock) in createMock()
68 throw new MockitoException("Failed to mock " + typeToMock, e); in createMock()
/external/dexmaker/
Dbug-8108255.patch6 classesToMock[0] = typeToMock;
9 @SuppressWarnings("unchecked") // newProxyInstance returns the type of typeToMock
10 - T mock = (T) Proxy.newProxyInstance(typeToMock.getClassLoader(),
/external/mockito/src/org/mockito/internal/
DMockitoCore.java43 public boolean isTypeMockable(Class<?> typeToMock) { in isTypeMockable() argument
44 return mockUtil.isTypeMockable(typeToMock); in isTypeMockable()
47 public <T> T mock(Class<T> typeToMock, MockSettings settings) { in mock() argument
54 MockCreationSettings<T> creationSettings = impl.confirm(typeToMock); in mock()
56 mockingProgress.mockingStarted(mock, typeToMock); in mock()