Home
last modified time | relevance | path

Searched refs:mock (Results 1 – 20 of 20) sorted by relevance

/art/libnativeloader/
Dnative_loader_test.cpp169 static std::unique_ptr<MockPlatform> mock; variable
178 return mock->mock_init_anonymous_namespace(false, sonames, search_path); in android_init_anonymous_namespace()
187 return TO_ANDROID_NAMESPACE(mock->mock_create_namespace(false, in android_create_namespace()
199 return mock->mock_link_namespaces(false, TO_MOCK_NAMESPACE(from), TO_MOCK_NAMESPACE(to), sonames); in android_link_namespaces()
203 return TO_ANDROID_NAMESPACE(mock->mock_get_exported_namespace(false, name)); in android_get_exported_namespace()
207 return mock->mock_dlopen_ext(false, filename, flags, TO_MOCK_NAMESPACE(info->library_namespace)); in android_dlopen_ext()
212 bool NativeBridgeIsSupported(const char* libpath) { return mock->NativeBridgeIsSupported(libpath); } in NativeBridgeIsSupported()
215 return TO_BRIDGED_NAMESPACE(mock->mock_get_exported_namespace(true, name)); in NativeBridgeGetExportedNamespace()
225 return TO_BRIDGED_NAMESPACE(mock->mock_create_namespace(true, in NativeBridgeCreateNamespace()
237 return mock->mock_link_namespaces(true, TO_MOCK_NAMESPACE(from), TO_MOCK_NAMESPACE(to), sonames); in NativeBridgeLinkNamespaces()
[all …]
Dlibnativeloader_test.map19 # The tests mock libdl_android and libnativebridge symbols, so export them
DAndroid.bp117 // libnativebridge statically through libart-gtest, but we need to mock
/art/libartservice/service/javatests/com/android/server/art/
DPrimaryDexUtilsTest.java25 import static org.mockito.Mockito.mock;
142 AndroidPackage pkg = mock(AndroidPackage.class); in createPackage()
144 var baseSplit = mock(AndroidPackageSplit.class); in createPackage()
149 var split0 = mock(AndroidPackageSplit.class); in createPackage()
154 var split1 = mock(AndroidPackageSplit.class); in createPackage()
159 var split2 = mock(AndroidPackageSplit.class); in createPackage()
164 var split3 = mock(AndroidPackageSplit.class); in createPackage()
169 var split4 = mock(AndroidPackageSplit.class); in createPackage()
203 PackageState pkgState = mock(PackageState.class); in createPackageState()
212 SharedLibrary libraryNative = mock(SharedLibrary.class); in createPackageState()
[all …]
DUtilsTest.java23 import static org.mockito.Mockito.mock;
97 var pkgState = mock(PackageState.class); in testGetAllAbis()
108 var pkgState = mock(PackageState.class); in testGetAllAbisTranslated()
119 var pkgState = mock(PackageState.class); in testGetAllAbisPrimaryOnly()
129 var pkgState = mock(PackageState.class); in testGetAllAbisNone()
147 var pkgState = mock(PackageState.class); in testGetAllAbisInvalidNativeIsa()
159 var pkgState = mock(PackageState.class); in testGetAllAbisUnsupportedTranslation()
DPrimaryDexopterTestBase.java24 import static org.mockito.Mockito.mock;
126 AndroidPackage pkg = mock(AndroidPackage.class); in createPackage()
127 var baseSplit = mock(AndroidPackageSplit.class); in createPackage()
132 var split0 = mock(AndroidPackageSplit.class); in createPackage()
137 var split1 = mock(AndroidPackageSplit.class); in createPackage()
156 PackageState pkgState = mock(PackageState.class); in createPackageState()
173 PackageUserState pkgUserState = mock(PackageUserState.class); in createPackageUserState()
DDumpHelperTest.java30 import static org.mockito.Mockito.mock;
155 var pkgState = mock(PackageState.class); in createPackageState()
161 .thenReturn(hasPackage ? mock(AndroidPackage.class) : null); in createPackageState()
232 var info1 = mock(CheckedSecondaryDexInfo.class); in setUpForFoo()
259 var info2 = mock(CheckedSecondaryDexInfo.class); in setUpForFoo()
DSecondaryDexopterTest.java33 import static org.mockito.Mockito.mock;
168 .thenReturn(mock(IArtdCancellationSignal.class)); in setUp()
230 var pkg = mock(AndroidPackage.class); in createPackage()
240 var pkgState = mock(PackageState.class); in createPackageState()
253 var dex1Info = mock(CheckedSecondaryDexInfo.class); in createSecondaryDexInfo()
262 var dex2Info = mock(CheckedSecondaryDexInfo.class); in createSecondaryDexInfo()
271 var dex3Info = mock(CheckedSecondaryDexInfo.class); in createSecondaryDexInfo()
DDexoptHelperTest.java32 import static org.mockito.Mockito.mock;
171 var failingPrimaryDexopter = mock(PrimaryDexopter.class); in testDexopt()
351 var dexopter = mock(PrimaryDexopter.class); in testDexoptCancelledDuringDex2oatInvocationsMultiThreaded()
400 var dexopter = mock(PrimaryDexopter.class); in testDexoptCancelledDuringDex2oatInvocationsOnCurrentThread()
625 var fooPrimaryDexopter = mock(PrimaryDexopter.class); in testCallbackWithFailureResults()
634 var barPrimaryDexopter = mock(PrimaryDexopter.class); in testCallbackWithFailureResults()
667 Consumer<OperationProgress> progressCallback = mock(Consumer.class); in testProgressCallback()
697 AndroidPackage pkg = mock(AndroidPackage.class); in createPackage()
699 var baseSplit = mock(AndroidPackageSplit.class); in createPackage()
702 var split0 = mock(AndroidPackageSplit.class); in createPackage()
[all …]
DDexUseManagerTest.java30 import static org.mockito.Mockito.mock;
145 .thenReturn(mock(Intent.class)); in setUp()
300 mBroadcastReceiverCaptor.getValue().onReceive(mContext, mock(Intent.class)); in verifyPrimaryDexMultipleEntries()
512 mBroadcastReceiverCaptor.getValue().onReceive(mContext, mock(Intent.class)); in verifySecondaryDexMultipleEntries()
850 AndroidPackage pkg = mock(AndroidPackage.class); in createPackage()
853 var baseSplit = mock(AndroidPackageSplit.class); in createPackage()
860 var split0 = mock(AndroidPackageSplit.class); in createPackage()
874 PackageState pkgState = mock(PackageState.class); in createPackageState()
DArtdRefCacheTest.java26 import static org.mockito.Mockito.mock;
173 var differentBinder = mock(IBinder.class); in testBinderDied()
DArtManagerLocalTest.java43 import static org.mockito.Mockito.mock;
291 .thenReturn(mock(Intent.class)); in setUp()
1125 var progressCallbackExecutor = mock(Executor.class); in testOnBoot()
1126 var progressCallback = mock(Consumer.class); in testOnBoot()
1403 mBroadcastReceiverCaptor.getValue().onReceive(mContext, mock(Intent.class)); in testCommitPreRebootStagedFiles()
1423 AndroidPackage pkg = mock(AndroidPackage.class); in createPackage()
1425 var baseSplit = mock(AndroidPackageSplit.class); in createPackage()
1431 var split0 = mock(AndroidPackageSplit.class); in createPackage()
1435 var split1 = mock(AndroidPackageSplit.class); in createPackage()
1449 PackageUserState pkgUserState = mock(PackageUserState.class); in createPackageUserState()
[all …]
DPreRebootDexoptJobTest.java29 import static org.mockito.Mockito.mock;
112 mJobParameters = mock(JobParameters.class); in setUp()
DPrimaryDexopterParameterizedTest.java37 import static org.mockito.Mockito.mock;
312 when(mArtd.createCancellationSignal()).thenReturn(mock(IArtdCancellationSignal.class)); in testDexopt()
DPrimaryDexopterTest.java33 import static org.mockito.Mockito.mock;
144 .thenReturn(mock(IArtdCancellationSignal.class)); in setUp()
680 var artdCancellationSignal = mock(IArtdCancellationSignal.class); in testDexoptCancelledBeforeDexopt()
712 var artdCancellationSignal = mock(IArtdCancellationSignal.class); in testDexoptCancelledDuringDexopt()
DBackgroundDexoptJobTest.java31 import static org.mockito.Mockito.mock;
/art/dex2oat/linker/
Dmulti_oat_relative_patcher_test.cc132 std::unique_ptr<MockPatcher> mock(new MockPatcher()); in MultiOatRelativePatcherTest() local
133 mock_ = mock.get(); in MultiOatRelativePatcherTest()
134 patcher_.relative_patcher_ = std::move(mock); in MultiOatRelativePatcherTest()
/art/libartservice/service/
DAndroid.bp110 // Used by tests to allow tests to mock the right classes.
245 // We need ExtendedMockito to mock static methods.
249 // Statically link against system server to allow us to mock system
/art/tools/bisection_search/
Dbisection_test.py21 from unittest.mock import Mock
/art/runtime/
Dsubtype_check_test.cc221 MockSubtypeCheck mock; in Lookup() local
222 mock.klass_ = klass; in Lookup()
223 return mock; in Lookup()