Home
last modified time | relevance | path

Searched refs:expect (Results 1 – 25 of 105) sorted by relevance

12345

/tools/tradefederation/core/tests/src/com/android/tradefed/device/
DWaitDeviceRecoveryTest.java57 EasyMock.expect(mMockMonitor.getSerialNumber()).andStubReturn("serial"); in setUp()
69 EasyMock.expect(mMockMonitor.getDeviceState()).andReturn(TestDeviceState.NOT_AVAILABLE); in testRecoverDevice_success()
70 … EasyMock.expect(mMockMonitor.waitForDeviceOnline(EasyMock.anyLong())).andReturn(mMockDevice); in testRecoverDevice_success()
71 EasyMock.expect(mMockMonitor.waitForDeviceShell(EasyMock.anyLong())).andReturn(true); in testRecoverDevice_success()
72 EasyMock.expect(mMockMonitor.waitForDeviceAvailable(EasyMock.anyLong())).andReturn( in testRecoverDevice_success()
74 … EasyMock.expect(mMockMonitor.waitForDeviceOnline(EasyMock.anyLong())).andReturn(mMockDevice); in testRecoverDevice_success()
88 EasyMock.expect(mMockMonitor.getDeviceState()).andReturn(TestDeviceState.NOT_AVAILABLE); in testRecoverDevice_unavailable()
89 EasyMock.expect(mMockMonitor.waitForDeviceOnline(EasyMock.anyLong())).andReturn(null); in testRecoverDevice_unavailable()
108 EasyMock.expect(mMockMonitor.getDeviceState()).andReturn(TestDeviceState.ONLINE); in testRecoverDevice_unresponsive()
109 EasyMock.expect(mMockMonitor.waitForDeviceOnline(EasyMock.anyLong())) in testRecoverDevice_unresponsive()
[all …]
DMockFileUtil.java41 EasyMock.expect(mockDevice.getFileEntry(rootPath)).andStubReturn(rootEntry); in setMockDirContents()
43 EasyMock.expect(rootEntry.isDirectory()).andStubReturn(isDir); in setMockDirContents()
44 EasyMock.expect(rootEntry.getFullEscapedPath()).andStubReturn(rootPath); in setMockDirContents()
45 EasyMock.expect(rootEntry.getName()).andStubReturn(rootPath); in setMockDirContents()
49 EasyMock.expect(childMockEntry.getName()).andStubReturn(childName); in setMockDirContents()
51 EasyMock.expect(childMockEntry.getFullEscapedPath()).andStubReturn(fullPath); in setMockDirContents()
52 EasyMock.expect(childMockEntry.isDirectory()).andStubReturn(Boolean.FALSE); in setMockDirContents()
56 EasyMock.expect(rootEntry.getChildren(EasyMock.anyBoolean())) in setMockDirContents()
73 EasyMock.expect(mockDevice.getFileEntry(rootPath)).andStubReturn(rootEntry); in setMockDirPath()
74 EasyMock.expect(rootEntry.getFullEscapedPath()).andStubReturn(rootPath); in setMockDirPath()
[all …]
DReconnectingRecoveryTest.java47 EasyMock.expect(mMockMonitor.getSerialNumber()).andStubReturn(SERIAL); in setUp()
57 EasyMock.expect(mMockMonitor.waitForDeviceOnline()).andReturn(mMockDevice); in testRecoverDevice_successOnFirstTry()
58 EasyMock.expect(mMockMonitor.waitForDeviceShell(EasyMock.anyLong())).andReturn(true); in testRecoverDevice_successOnFirstTry()
59 EasyMock.expect(mMockMonitor.waitForDeviceAvailable()).andReturn(mMockDevice); in testRecoverDevice_successOnFirstTry()
72 EasyMock.expect(mMockMonitor.waitForDeviceOnline()).andReturn(null); in testRecoverDevice_successRetrying()
74 EasyMock.expect(mMockRunUtil.runTimedCmd(EasyMock.anyLong(), connectCommand())).andReturn( in testRecoverDevice_successRetrying()
76 EasyMock.expect(mMockMonitor.waitForDeviceOnline()).andReturn(mMockDevice); in testRecoverDevice_successRetrying()
77 EasyMock.expect(mMockMonitor.waitForDeviceShell(EasyMock.anyLong())).andReturn(true); in testRecoverDevice_successRetrying()
78 EasyMock.expect(mMockMonitor.waitForDeviceAvailable()).andReturn(mMockDevice); in testRecoverDevice_successRetrying()
90 EasyMock.expect(mMockMonitor.waitForDeviceOnline()).andStubReturn(null); in testRecoverDevice_failure()
[all …]
DDeviceManagerTest.java192 EasyMock.expect(mMockIDevice.getSerialNumber()).andStubReturn(DEVICE_SERIAL); in setUp()
193 EasyMock.expect(mMockStateMonitor.getSerialNumber()).andStubReturn(DEVICE_SERIAL); in setUp()
194 EasyMock.expect(mMockIDevice.isEmulator()).andStubReturn(Boolean.FALSE); in setUp()
195 EasyMock.expect(mMockTestDevice.getMacAddress()).andStubReturn(MAC_ADDRESS); in setUp()
196 EasyMock.expect(mMockTestDevice.getSimState()).andStubReturn(SIM_STATE); in setUp()
197 EasyMock.expect(mMockTestDevice.getSimOperator()).andStubReturn(SIM_OPERATOR); in setUp()
201 EasyMock.expect(mMockTestDevice.getIDevice()).andStubAnswer(new IAnswer<IDevice>() { in setUp()
207 EasyMock.expect(mMockTestDevice.getSerialNumber()).andStubAnswer(new IAnswer<String>() { in setUp()
213 EasyMock.expect(mMockTestDevice.getMonitor()).andStubReturn(mMockStateMonitor); in setUp()
214 EasyMock.expect( in setUp()
[all …]
DDeviceStateMonitorTest.java52 EasyMock.expect(mMockDevice.getState()).andReturn(DeviceState.ONLINE); in setUp()
53 EasyMock.expect(mMockDevice.getSerialNumber()).andReturn(SERIAL_NUMBER).anyTimes(); in setUp()
97 EasyMock.expect(mockDevice.getSerialNumber()).andStubReturn("2345asdf"); in testIsAdbTcp_usb()
98 EasyMock.expect(mockDevice.getState()).andReturn(DeviceState.ONLINE); in testIsAdbTcp_usb()
109 EasyMock.expect(mockDevice.getSerialNumber()).andStubReturn("192.168.1.1:5555"); in testIsAdbTcp_tcp()
110 EasyMock.expect(mockDevice.getState()).andReturn(DeviceState.ONLINE); in testIsAdbTcp_tcp()
161 EasyMock.expect(mMockDevice.getState()).andReturn(DeviceState.ONLINE); in testWaitForShellAvailable()
162 EasyMock.expect(mMockDevice.getSerialNumber()).andReturn(SERIAL_NUMBER).anyTimes(); in testWaitForShellAvailable()
188 EasyMock.expect(mMockDevice.getState()).andReturn(DeviceState.ONLINE); in testWaitForShell_becomeAvailable()
189 EasyMock.expect(mMockDevice.getSerialNumber()).andReturn(SERIAL_NUMBER).anyTimes(); in testWaitForShell_becomeAvailable()
[all …]
DDeviceSelectionOptionsTest.java71 EasyMock.expect(mMockDevice.getSerialNumber()).andStubReturn(DEVICE_SERIAL); in setUp()
72 EasyMock.expect(mMockDevice.isEmulator()).andStubReturn(Boolean.FALSE); in setUp()
74 EasyMock.expect(mMockEmulatorDevice.getSerialNumber()).andStubReturn("emulator"); in setUp()
75 EasyMock.expect(mMockEmulatorDevice.isEmulator()).andStubReturn(Boolean.TRUE); in setUp()
153 EasyMock.expect(mMockDevice.getProperty(DeviceProperties.VARIANT)).andReturn(null);
154 EasyMock.expect(mMockDevice.getProperty(DeviceProperties.VARIANT_LEGACY))
165 EasyMock.expect(mMockDevice.getProperty(DeviceProperties.VARIANT)).andReturn("variant");
166 EasyMock.expect(mMockDevice.getProperty(DeviceProperties.VARIANT_LEGACY))
178 EasyMock.expect(mMockDevice.getProperty(DeviceProperties.BOARD)).andReturn(DEVICE_TYPE);
179 EasyMock.expect(mMockDevice.getProperty(DeviceProperties.VARIANT)).andReturn(null);
[all …]
/tools/tradefederation/core/tests/src/com/android/tradefed/targetprep/
DDefaultTestsZipInstallerTest.java76 EasyMock.expect(mMockDevice.getSerialNumber()).andStubReturn(TEST_STRING); in setUp()
77 EasyMock.expect(mMockDevice.getProductType()).andStubReturn(TEST_STRING); in setUp()
78 EasyMock.expect(mMockDevice.getBuildId()).andStubReturn("1"); in setUp()
80 EasyMock.expect(mMockDevice.getDeviceDescriptor()).andStubReturn(null); in setUp()
104 EasyMock.expect(mMockDevice.getSerialNumber()).andStubReturn("serial_number_stub"); in testCantTouchFilesystem()
105 EasyMock.expect(mMockDevice.getRecoveryMode()).andReturn(RecoveryMode.AVAILABLE); in testCantTouchFilesystem()
106 EasyMock.expect(mMockDevice.executeShellCommand("stop")).andReturn(""); in testCantTouchFilesystem()
107 EasyMock.expect(mMockDevice.executeShellCommand("stop installd")).andReturn(""); in testCantTouchFilesystem()
111 EasyMock.expect(mMockDevice.pushString((String) EasyMock.anyObject(), in testCantTouchFilesystem()
135 EasyMock.expect(mMockDevice.getSerialNumber()).andStubReturn("serial_number_stub"); in testPushTestsZipOntoData()
[all …]
DSdkAvdPreparerTest.java73 EasyMock.expect(mMockBuildInfo.getAndroidToolPath()).andStubReturn(ANDROID_TOOL); in setUp()
74 EasyMock.expect(mMockBuildInfo.getEmulatorToolPath()).andStubReturn(EMULATOR_TOOL); in setUp()
75 EasyMock.expect(mMockBuildInfo.getSdkDir()).andStubReturn(new File("sdk")); in setUp()
76 EasyMock.expect(mMockDevice.getIDevice()).andStubReturn(mMockIDevice); in setUp()
77 EasyMock.expect(mMockDevice.getSerialNumber()).andStubReturn("serial"); in setUp()
78 EasyMock.expect(mMockDevice.getDeviceDescriptor()).andStubReturn(null); in setUp()
114 EasyMock.expect(mMockDevice.getDeviceState()).andReturn(TestDeviceState.NOT_AVAILABLE); in testSetUp()
115 EasyMock.expect(mMockDevice.getSerialNumber()).andReturn("emulator-5554").anyTimes(); in testSetUp()
116 EasyMock.expect(mMockIDevice.isEmulator()).andReturn(true); in testSetUp()
120 EasyMock.expect(mMockDevice.executeShellCommand((String) EasyMock.anyObject())) in testSetUp()
[all …]
DFastbootDeviceFlasherTest.java64 EasyMock.expect(mMockDevice.getSerialNumber()).andStubReturn(TEST_STRING); in setUp()
65 EasyMock.expect(mMockDevice.getProductType()).andStubReturn(TEST_STRING); in setUp()
66 EasyMock.expect(mMockDevice.getBuildId()).andStubReturn("1"); in setUp()
67 EasyMock.expect(mMockDevice.getBuildFlavor()).andStubReturn("test-debug"); in setUp()
68 EasyMock.expect(mMockDevice.getDeviceDescriptor()).andStubReturn(null); in setUp()
116 EasyMock.expect(mMockParser.getRequiredBoards()).andReturn(null); in testFlash_missingBoard()
135 EasyMock.expect(mMockDevice.executeFastbootCommand("getvar", "version-bootloader")). in testGetImageVersion()
151 EasyMock.expect(mMockDevice.getDeviceState()).andReturn(TestDeviceState.FASTBOOT); in testGetCurrentSlot_fastboot()
152 EasyMock.expect(mMockDevice.executeFastbootCommand("getvar", "current-slot")) in testGetCurrentSlot_fastboot()
163 EasyMock.expect(mMockDevice.getDeviceState()).andReturn(TestDeviceState.ONLINE); in testGetCurrentSlot_adb()
[all …]
DDeviceStringPusherTest.java50 EasyMock.expect(mMockDevice.doesFileExist("file")).andReturn(false).once(); in testFail()
51 EasyMock.expect(mMockDevice.pushString("hi", "file")).andReturn(false).once(); in testFail()
52 EasyMock.expect(mMockDevice.getDeviceDescriptor()).andReturn(null).once(); in testFail()
63 EasyMock.expect(mMockDevice.doesFileExist("file")).andReturn(false).once(); in testDoesntExist()
64 EasyMock.expect(mMockDevice.pushString("hi", "file")).andReturn(true).once(); in testDoesntExist()
65 EasyMock.expect(mMockDevice.executeShellCommand("rm -f file")).andReturn(null).once(); in testDoesntExist()
79 EasyMock.expect(mMockDevice.doesFileExist("file")).andReturn(true).once(); in testAlreadyExists()
80 EasyMock.expect(mMockDevice.pullFile("file")).andReturn(file).once(); in testAlreadyExists()
81 EasyMock.expect(mMockDevice.pushString("hi", "file")).andReturn(true).once(); in testAlreadyExists()
82 EasyMock.expect(mMockDevice.pushFile(file, "file")).andReturn(true).once(); in testAlreadyExists()
DSystemUpdaterDeviceFlasherTest.java54 EasyMock.expect(mMockDevice.getSerialNumber()).andStubReturn(TEST_STRING); in setUp()
55 EasyMock.expect(mMockDevice.getProductType()).andStubReturn(TEST_STRING); in setUp()
56 EasyMock.expect(mMockDevice.getDeviceDescriptor()).andStubReturn(null); in setUp()
63 EasyMock.expect(mMockDeviceBuild.getOtaPackageFile()).andReturn(fakeImage); in testFlash()
64 EasyMock.expect(mMockDevice.pushFile(fakeImage, "/cache/update.zip")).andReturn(true); in testFlash()
67 EasyMock.expect(mMockDevice.executeShellCommand(EasyMock.matches(commandsRegex))).andReturn( in testFlash()
80 EasyMock.expect(mMockDeviceBuild.getOtaPackageFile()).andReturn(null); in testFlash_noOta()
102 EasyMock.expect(mMockDevice.getBuildId()).andReturn(A_BUILD_ID).anyTimes(); in yieldDifferentBuilds()
103 EasyMock.expect(mMockDeviceBuild.getDeviceBuildId()).andReturn( in yieldDifferentBuilds()
DDeviceFlashPreparerTest.java67 EasyMock.expect(mMockDevice.getSerialNumber()).andReturn("foo").anyTimes(); in setUp()
68 EasyMock.expect(mMockDevice.getOptions()).andReturn(new TestDeviceOptions()).anyTimes(); in setUp()
119 EasyMock.expect(mMockFlasher.getSystemFlashingStatus()) in testSetup()
138 EasyMock.expect(mMockDevice.enableAdbRoot()).andStubReturn(Boolean.TRUE); in doSetupExpectations()
140 EasyMock.expect(mMockDevice.getBuildId()).andReturn(mMockBuildInfo.getBuildId()); in doSetupExpectations()
141 EasyMock.expect(mMockDevice.getBuildFlavor()).andReturn(mMockBuildInfo.getBuildFlavor()); in doSetupExpectations()
142 EasyMock.expect(mMockDevice.isEncryptionSupported()).andStubReturn(Boolean.TRUE); in doSetupExpectations()
143 EasyMock.expect(mMockDevice.isDeviceEncrypted()).andStubReturn(Boolean.FALSE); in doSetupExpectations()
174 EasyMock.expect(mMockDevice.enableAdbRoot()).andStubReturn(Boolean.TRUE); in testSetup_buildError()
176 EasyMock.expect(mMockDevice.getBuildId()).andReturn(mMockBuildInfo.getBuildId()); in testSetup_buildError()
[all …]
DRestartSystemServerTargetPreparerTest.java46 EasyMock.expect(mMockDevice.enableAdbRoot()).andReturn(true).once(); in testSetUp_bootComplete()
47 EasyMock.expect(mMockDevice.executeShellCommand("setprop dev.bootcomplete 0")) in testSetUp_bootComplete()
49 EasyMock.expect( in testSetUp_bootComplete()
64 EasyMock.expect(mMockDevice.enableAdbRoot()).andReturn(true).once(); in testSetUp_bootNotComplete()
65 EasyMock.expect(mMockDevice.executeShellCommand("setprop dev.bootcomplete 0")) in testSetUp_bootNotComplete()
67 EasyMock.expect( in testSetUp_bootNotComplete()
85 EasyMock.expect(mMockDevice.enableAdbRoot()).andReturn(true).once(); in testTearDown_restart()
86 EasyMock.expect(mMockDevice.executeShellCommand("setprop dev.bootcomplete 0")) in testTearDown_restart()
88 EasyMock.expect( in testTearDown_restart()
DRootTargetPreparerTest.java44 EasyMock.expect(mMockDevice.isAdbRoot()).andReturn(true).once(); in testSetUpSuccess_rootBefore()
54 EasyMock.expect(mMockDevice.isAdbRoot()).andReturn(false).once(); in testSetUpSuccess_notRootBefore()
55 EasyMock.expect(mMockDevice.enableAdbRoot()).andReturn(true).once(); in testSetUpSuccess_notRootBefore()
56 EasyMock.expect(mMockDevice.disableAdbRoot()).andReturn(true).once(); in testSetUpSuccess_notRootBefore()
66 EasyMock.expect(mMockDevice.isAdbRoot()).andReturn(false).once(); in testSetUpFail()
67 EasyMock.expect(mMockDevice.enableAdbRoot()).andReturn(false).once(); in testSetUpFail()
68 EasyMock.expect(mMockDevice.getDeviceDescriptor()).andReturn(null).once(); in testSetUpFail()
DAppSetupTest.java63 EasyMock.expect(mMockDevice.getSerialNumber()).andStubReturn(SERIAL); in setUp()
64 EasyMock.expect(mMockDevice.getDeviceDescriptor()).andStubReturn(null); in setUp()
103 EasyMock.expect(mMockBuildInfo.getAppPackageFiles()).andReturn(files); in testSetup_failToInstall()
104 EasyMock.expect(mMockDevice.installPackage(EasyMock.eq(tmpFile), EasyMock.eq(true))) in testSetup_failToInstall()
128 EasyMock.expect(mMockBuildInfo.getAppPackageFiles()).andReturn(files); in testSetup_aaptCannotParse()
129 EasyMock.expect(mMockDevice.installPackage(EasyMock.eq(tmpFile), EasyMock.eq(true))) in testSetup_aaptCannotParse()
159 EasyMock.expect(mMockBuildInfo.getAppPackageFiles()).andReturn(files); in testSetup_noPackageName()
160 EasyMock.expect(mMockDevice.installPackage(EasyMock.eq(tmpFile), EasyMock.eq(true))) in testSetup_noPackageName()
194 EasyMock.expect(mMockBuildInfo.getAppPackageFiles()).andReturn(files); in testSetup_checkMinSdk_failParsing()
225 EasyMock.expect(mMockBuildInfo.getAppPackageFiles()).andReturn(files); in testSetup_checkMinSdk_apiLow()
[all …]
/tools/tradefederation/core/tests/src/com/android/tradefed/invoker/
DTestInvocationMultiTest.java109 EasyMock.expect(mDevice1.getIDevice()).andStubReturn(new StubDevice("serial1")); in makeTwoDeviceContext()
110 EasyMock.expect(mDevice1.getSerialNumber()).andStubReturn("serial1"); in makeTwoDeviceContext()
115 EasyMock.expect(mMockConfig.getDeviceConfigByName("device1")).andStubReturn(holder1); in makeTwoDeviceContext()
120 EasyMock.expect(mDevice2.getIDevice()).andStubReturn(new StubDevice("serial2")); in makeTwoDeviceContext()
121 EasyMock.expect(mDevice2.getSerialNumber()).andStubReturn("serial2"); in makeTwoDeviceContext()
126 EasyMock.expect(mMockConfig.getDeviceConfigByName("device2")).andStubReturn(holder2); in makeTwoDeviceContext()
143 EasyMock.expect(mMockConfig.getTestInvocationListeners()) in testRunBuildProvider_oneMiss()
146 EasyMock.expect(mMockConfig.getLogSaver()).andReturn(mMockLogSaver); in testRunBuildProvider_oneMiss()
147 EasyMock.expect(mMockConfig.getLogOutput()).andReturn(mMockLogger).times(4); in testRunBuildProvider_oneMiss()
148 EasyMock.expect(mMockConfig.getConfigurationDescription()).andReturn(mConfigDesc); in testRunBuildProvider_oneMiss()
[all …]
DTestInvocationTest.java175 EasyMock.expect(mMockPreparer.isDisabled()).andStubReturn(false); in setUp()
176 EasyMock.expect(mMockPreparer.isTearDownDisabled()).andStubReturn(false); in setUp()
198 EasyMock.expect(mMockDevice.getSerialNumber()).andStubReturn(SERIAL); in setUp()
199 EasyMock.expect(mMockDevice.getIDevice()).andStubReturn(null); in setUp()
207 EasyMock.expect(mMockDevice.getDeviceDescriptor()).andStubReturn(mFakeDescriptor); in setUp()
209 EasyMock.expect(mMockBuildInfo.getBuildId()).andStubReturn("1"); in setUp()
210 EasyMock.expect(mMockBuildInfo.getBuildAttributes()).andStubReturn(EMPTY_MAP); in setUp()
211 EasyMock.expect(mMockBuildInfo.getBuildBranch()).andStubReturn("branch"); in setUp()
212 EasyMock.expect(mMockBuildInfo.getBuildFlavor()).andStubReturn("flavor"); in setUp()
213 EasyMock.expect(mMockBuildInfo.getProperties()).andStubReturn(new HashSet<>()); in setUp()
[all …]
/tools/tradefederation/core/tests/src/com/android/tradefed/testtype/
DGoogleBenchmarkTestTest.java53 EasyMock.expect(mMockITestDevice.getSerialNumber()).andStubReturn("serial"); in setUp()
95 EasyMock.expect(mMockITestDevice.doesFileExist(nativeTestPath)).andReturn(true); in testRun()
96 EasyMock.expect(mMockITestDevice.isDirectory(nativeTestPath)).andReturn(true); in testRun()
97 EasyMock.expect(mMockITestDevice.isDirectory(nativeTestPath + "/test1")).andReturn(false); in testRun()
98 EasyMock.expect(mMockITestDevice.isDirectory(nativeTestPath + "/test2")).andReturn(false); in testRun()
100 EasyMock.expect(mMockITestDevice.getChildren(nativeTestPath)).andReturn(files); in testRun()
101 EasyMock.expect(mMockITestDevice.executeShellCommand(EasyMock.contains("chmod"))) in testRun()
107 EasyMock.expect( in testRun()
111 EasyMock.expect( in testRun()
116 EasyMock.expect( in testRun()
[all …]
DGTestTest.java60 EasyMock.expect(mMockITestDevice.getSerialNumber()).andStubReturn("serial"); in setUp()
101 EasyMock.expect(mMockITestDevice.doesFileExist(GTest.DEFAULT_NATIVETEST_PATH)) in testRun_noTestDir()
132 EasyMock.expect(mMockITestDevice.doesFileExist(nativeTestPath)).andReturn(true); in testRun()
133 EasyMock.expect(mMockITestDevice.isDirectory(nativeTestPath)).andReturn(true); in testRun()
134 EasyMock.expect(mMockITestDevice.isDirectory(nativeTestPath + "/test1")).andReturn(false); in testRun()
136 EasyMock.expect(mMockITestDevice.executeShellCommand("ls -l " + testPath1)) in testRun()
138 EasyMock.expect(mMockITestDevice.isDirectory(nativeTestPath + "/test2")).andReturn(false); in testRun()
139 EasyMock.expect(mMockITestDevice.executeShellCommand("ls -l " + testPath2)) in testRun()
142 EasyMock.expect(mMockITestDevice.getChildren(nativeTestPath)).andReturn(files); in testRun()
166 EasyMock.expect(mMockITestDevice.doesFileExist(modulePath)).andReturn(true); in testRun_moduleName()
[all …]
/tools/tradefederation/core/tests/src/com/android/tradefed/build/
DBootstrapBuildProviderTest.java44 EasyMock.expect(mMockDevice.getBuildId()).andReturn("5"); in testGetBuild()
45 EasyMock.expect(mMockDevice.getIDevice()).andReturn(EasyMock.createMock(IDevice.class)); in testGetBuild()
46 EasyMock.expect(mMockDevice.waitForDeviceShell(EasyMock.anyLong())).andReturn(true); in testGetBuild()
47 EasyMock.expect(mMockDevice.getProperty(EasyMock.anyObject())).andStubReturn("property"); in testGetBuild()
48 EasyMock.expect(mMockDevice.getProductVariant()).andStubReturn("variant"); in testGetBuild()
49 EasyMock.expect(mMockDevice.getBuildFlavor()).andStubReturn("flavor"); in testGetBuild()
50 EasyMock.expect(mMockDevice.getBuildAlias()).andStubReturn("alias"); in testGetBuild()
70 EasyMock.expect(mMockDevice.getBuildId()).andReturn("5"); in testGetBuild_stubDevice()
71 EasyMock.expect(mMockDevice.getIDevice()).andReturn(new StubDevice("serial")); in testGetBuild_stubDevice()
72 EasyMock.expect(mMockDevice.getBuildFlavor()).andStubReturn("flavor"); in testGetBuild_stubDevice()
[all …]
/tools/tradefederation/core/tests/src/com/android/tradefed/util/
DAbiFormatterTest.java50 EasyMock.expect(device.getProperty("ro.product.cpu.abilist32")).andReturn(null); in testGetDefaultAbi()
51 EasyMock.expect(device.getProperty("ro.product.cpu.abi")).andReturn(null); in testGetDefaultAbi()
56 EasyMock.expect(device.getProperty(EasyMock.eq("ro.product.cpu.abilist32"))) in testGetDefaultAbi()
62 EasyMock.expect(device.getProperty(EasyMock.eq("ro.product.cpu.abilist64"))).andReturn(""); in testGetDefaultAbi()
63 EasyMock.expect(device.getProperty("ro.product.cpu.abi")).andReturn(null); in testGetDefaultAbi()
74 EasyMock.expect(device.getProperty("ro.product.cpu.abilist32")).andReturn("abi1,abi2"); in testGetSupportedAbis()
81 EasyMock.expect(device.getProperty("ro.product.cpu.abilist32")).andReturn(null); in testGetSupportedAbis()
82 EasyMock.expect(device.getProperty("ro.product.cpu.abi")).andReturn("abi"); in testGetSupportedAbis()
88 EasyMock.expect(device.getProperty("ro.product.cpu.abilist")).andReturn(""); in testGetSupportedAbis()
89 EasyMock.expect(device.getProperty("ro.product.cpu.abi")).andReturn("abi"); in testGetSupportedAbis()
/tools/tradefederation/core/tests/src/com/android/tradefed/testtype/suite/module/
DNativeBridgeModuleControllerTest.java57 EasyMock.expect(mMockDevice.getIDevice()).andReturn(new StubDevice("serial")); in testStubDevice()
66 EasyMock.expect(mMockDevice.getIDevice()).andReturn(mMockIDevice); in testNoBridgeSupport()
67 EasyMock.expect(mMockDevice.getProperty(NativeBridgeModuleController.NATIVE_BRIDGE_PROP)) in testNoBridgeSupport()
80 EasyMock.expect(mMockDevice.getIDevice()).andReturn(mMockIDevice); in testBridgeSupport()
81 EasyMock.expect(mMockDevice.getProperty(NativeBridgeModuleController.NATIVE_BRIDGE_PROP)) in testBridgeSupport()
83 EasyMock.expect(mMockDevice.getProperty("ro.product.cpu.abilist")) in testBridgeSupport()
96 EasyMock.expect(mMockDevice.getIDevice()).andReturn(mMockIDevice); in testBridgeSupport_differentBitness()
97 EasyMock.expect(mMockDevice.getProperty(NativeBridgeModuleController.NATIVE_BRIDGE_PROP)) in testBridgeSupport_differentBitness()
99 EasyMock.expect(mMockDevice.getProperty("ro.product.cpu.abilist")) in testBridgeSupport_differentBitness()
112 EasyMock.expect(mMockDevice.getIDevice()).andReturn(mMockIDevice); in testBridgeSupport_differentArch()
[all …]
/tools/tradefederation/core/tests/src/com/android/tradefed/result/
DDeviceFileReporterTest.java64 EasyMock.expect(mDevice.getSerialNumber()).andStubReturn("serial"); in setUp()
82 EasyMock.expect(mDevice.executeShellCommand(EasyMock.eq("ls /data/tombstones/*"))) in testSimple()
85 EasyMock.expect(mDevice.pullFile(EasyMock.eq(filename))) in testSimple()
107 EasyMock.expect(mDevice.executeShellCommand(EasyMock.eq("ls /data/tombstones/*"))) in testTrim()
110 EasyMock.expect(mDevice.pullFile(EasyMock.eq(filename))) in testTrim()
133 EasyMock.expect(mDevice.executeShellCommand((String)EasyMock.anyObject())) in testLineEnding_LF()
138 EasyMock.expect(mDevice.pullFile(EasyMock.eq(filename))).andReturn( in testLineEnding_LF()
160 EasyMock.expect(mDevice.executeShellCommand((String)EasyMock.anyObject())) in testLineEnding_CRLF()
165 EasyMock.expect(mDevice.pullFile(EasyMock.eq(filename))).andReturn( in testLineEnding_CRLF()
212 EasyMock.expect(mDevice.executeShellCommand((String)EasyMock.anyObject())) in testRepeat_skip()
[all …]
/tools/tradefederation/core/tests/src/com/android/tradefed/testtype/suite/
DTestFailureListenerTest.java53 EasyMock.expect(mMockDevice.getSerialNumber()).andStubReturn("SERIAL"); in setUp()
68 EasyMock.expect(mMockDevice.getDeviceDate()).andReturn(startDate); in testTestFailed()
70 EasyMock.expect(mMockDevice.getScreenshot()).andReturn(fakeSource); in testTestFailed()
76 EasyMock.expect(mMockDevice.logBugreport(EasyMock.anyObject(), EasyMock.anyObject())) in testTestFailed()
79 EasyMock.expect(mMockDevice.getLogcatSince(EasyMock.eq(startDate))).andReturn(fakeSource); in testTestFailed()
85 EasyMock.expect(mMockDevice.getProperty(EasyMock.eq("ro.build.type"))) in testTestFailed()
115 EasyMock.expect(mMockDevice.getDeviceDate()).andThrow(dnae); in testTestFailed_notAvailable()
117 EasyMock.expect(mMockDevice.getScreenshot()).andThrow(dnae); in testTestFailed_notAvailable()
119 EasyMock.expect(mMockDevice.getLogcat(EasyMock.anyInt())).andReturn(fakeSource); in testTestFailed_notAvailable()
125 EasyMock.expect(mMockDevice.getProperty(EasyMock.eq("ro.build.type"))) in testTestFailed_notAvailable()
[all …]
/tools/tradefederation/core/tests/src/com/android/tradefed/command/
DCommandSchedulerFuncTest.java95 EasyMock.expect(mSlowConfig.getCommandOptions()).andStubReturn(mCommandOptions); in setUp()
96 EasyMock.expect(mSlowConfig.getTestInvocationListeners()) in setUp()
98 EasyMock.expect(mFastConfig.getCommandOptions()).andStubReturn(mCommandOptions); in setUp()
99 EasyMock.expect(mFastConfig.getTestInvocationListeners()) in setUp()
101 EasyMock.expect(mSlowConfig.getDeviceRequirements()).andStubReturn( in setUp()
103 EasyMock.expect(mFastConfig.getDeviceRequirements()).andStubReturn( in setUp()
105 EasyMock.expect(mSlowConfig.getDeviceConfig()).andStubReturn(mMockDeviceConfig); in setUp()
106 EasyMock.expect(mSlowConfig.getDeviceConfigByName(EasyMock.eq("device"))) in setUp()
108 EasyMock.expect(mSlowConfig.getCommandLine()).andStubReturn(""); in setUp()
109 EasyMock.expect(mFastConfig.getDeviceConfigByName(EasyMock.eq("device"))) in setUp()
[all …]

12345