Home
last modified time | relevance | path

Searched refs:mMockIDevice (Results 1 – 12 of 12) sorted by relevance

/tools/tradefederation/core/tests/src/com/android/tradefed/testtype/suite/module/
DNativeBridgeModuleControllerTest.java41 private IDevice mMockIDevice; field in NativeBridgeModuleControllerTest
51 mMockIDevice = EasyMock.createMock(IDevice.class); in setUp()
66 EasyMock.expect(mMockDevice.getIDevice()).andReturn(mMockIDevice); in testNoBridgeSupport()
69 EasyMock.replay(mMockDevice, mMockIDevice); in testNoBridgeSupport()
71 EasyMock.verify(mMockDevice, mMockIDevice); in testNoBridgeSupport()
80 EasyMock.expect(mMockDevice.getIDevice()).andReturn(mMockIDevice); in testBridgeSupport()
85 EasyMock.replay(mMockDevice, mMockIDevice); in testBridgeSupport()
87 EasyMock.verify(mMockDevice, mMockIDevice); in testBridgeSupport()
96 EasyMock.expect(mMockDevice.getIDevice()).andReturn(mMockIDevice); in testBridgeSupport_differentBitness()
101 EasyMock.replay(mMockDevice, mMockIDevice); in testBridgeSupport_differentBitness()
[all …]
/tools/tradefederation/core/tests/src/com/android/tradefed/device/
DNativeDeviceTest.java76 private IDevice mMockIDevice; field in NativeDeviceTest
92 super(mMockIDevice, mMockStateMonitor, mMockDvcMonitor); in TestableAndroidNativeDevice()
112 mMockIDevice = EasyMock.createMock(IDevice.class); in setUp()
113 EasyMock.expect(mMockIDevice.getSerialNumber()).andReturn(MOCK_DEVICE_SERIAL).anyTimes(); in setUp()
131 return mMockIDevice; in setUp()
698 EasyMock.replay(mMockWifi, mMockIDevice); in testConnectToWifiNetwork_success()
701 EasyMock.verify(mMockWifi, mMockIDevice); in testConnectToWifiNetwork_success()
718 EasyMock.replay(mMockWifi, mMockIDevice, mMockRunUtil); in testConnectToWifiNetwork_failure()
721 EasyMock.verify(mMockWifi, mMockIDevice, mMockRunUtil); in testConnectToWifiNetwork_failure()
748 EasyMock.replay(mMockWifi, mMockIDevice); in testConnectToWifiNetwork_maxConnectTime()
[all …]
DBackgroundDeviceActionTest.java40 private IDevice mMockIDevice; field in BackgroundDeviceActionTest
54 mMockIDevice = EasyMock.createMock(IDevice.class); in setUp()
55 EasyMock.expect(mMockIDevice.getSerialNumber()).andReturn(MOCK_DEVICE_SERIAL).anyTimes(); in setUp()
59 EasyMock.expect(mMockTestDevice.getIDevice()).andReturn(mMockIDevice).anyTimes(); in setUp()
70 mMockIDevice.executeShellCommand(EasyMock.eq(action), EasyMock.same(mMockReceiver), in testBackgroundActionComplete()
73 EasyMock.replay(mMockTestDevice, mMockIDevice, mMockReceiver); in testBackgroundActionComplete()
92 mMockIDevice.executeShellCommand(EasyMock.eq(action), EasyMock.same(mMockReceiver), in testBackgroundAction_shellException()
95 EasyMock.replay(mMockTestDevice, mMockIDevice, mMockReceiver); in testBackgroundAction_shellException()
124 EasyMock.replay(mMockTestDevice, mMockIDevice, mMockReceiver); in testwaitForDeviceRecovery_online()
149 EasyMock.replay(mMockTestDevice, mMockIDevice, mMockReceiver); in testwaitForDeviceRecovery_blockOffline()
DTestDeviceTest.java84 private IDevice mMockIDevice; field in TestDeviceTest
100 super(mMockIDevice, mMockStateMonitor, mMockDvcMonitor); in TestableTestDevice()
130 mMockIDevice = EasyMock.createMock(IDevice.class); in setUp()
131 EasyMock.expect(mMockIDevice.getSerialNumber()).andReturn(MOCK_DEVICE_SERIAL).anyTimes(); in setUp()
175 EasyMock.replay(mMockIDevice); in testEnableAdbRoot_alreadyRoot()
184 EasyMock.replay(mMockIDevice, mMockRunUtil, mMockStateMonitor); in testEnableAdbRoot_notRoot()
207 EasyMock.replay(mMockIDevice); in testDisableAdbRoot_alreadyUnroot()
209 EasyMock.verify(mMockIDevice); in testDisableAdbRoot_alreadyUnroot()
225 mMockIDevice); in testDisableAdbRoot_unroot()
226 EasyMock.replay(mMockIDevice, mMockRunUtil, mMockStateMonitor); in testDisableAdbRoot_unroot()
[all …]
DDeviceManagerTest.java59 private IDevice mMockIDevice; field in DeviceManagerTest
164 mMockIDevice = EasyMock.createMock(IDevice.class); in setUp()
192 EasyMock.expect(mMockIDevice.getSerialNumber()).andStubReturn(DEVICE_SERIAL); in setUp()
194 EasyMock.expect(mMockIDevice.isEmulator()).andStubReturn(Boolean.FALSE); in setUp()
290 DeviceManager manager = createDeviceManager(null, mMockIDevice); in testAllocateDevice()
306 DeviceManager manager = createDeviceManager(null, mMockIDevice); in testAllocateDevice_match()
320 EasyMock.expect(mMockIDevice.isEmulator()).andStubReturn(Boolean.TRUE); in testAllocateDevice_stubEmulator()
339 EasyMock.expect(mMockIDevice.isEmulator()).andStubReturn(Boolean.TRUE); in testFreeDevice_emulator()
372 EasyMock.expect(mMockIDevice.isEmulator()).andStubReturn(Boolean.FALSE); in testAllocateDevice_nullDevice()
439 DeviceManager manager = createDeviceManager(null, mMockIDevice); in testForceAllocateDevice_available()
[all …]
DRemoteAndroidDeviceTest.java33 private IDevice mMockIDevice; field in RemoteAndroidDeviceTest
45 super(mMockIDevice, mMockStateMonitor, mMockDvcMonitor); in TestableRemoteAndroidDevice()
60 mMockIDevice = EasyMock.createMock(IDevice.class); in setUp()
61 EasyMock.expect(mMockIDevice.getSerialNumber()).andReturn(MOCK_DEVICE_SERIAL).anyTimes(); in setUp()
153 EasyMock.replay(mMockIDevice); in testCheckSerial()
159 mMockIDevice = EasyMock.createMock(IDevice.class); in testCheckSerial_invalid()
160 EasyMock.expect(mMockIDevice.getSerialNumber()).andReturn("wrongserial").anyTimes(); in testCheckSerial_invalid()
/tools/tradefederation/core/tests/src/com/android/tradefed/targetprep/
DSdkAvdPreparerTest.java51 private IDevice mMockIDevice; field in SdkAvdPreparerTest
70 mMockIDevice = EasyMock.createMock(IDevice.class); in setUp()
76 EasyMock.expect(mMockDevice.getIDevice()).andStubReturn(mMockIDevice); in setUp()
116 EasyMock.expect(mMockIDevice.isEmulator()).andReturn(true); in testSetUp()
125 EasyMock.expect(mMockIDevice.getAvdName()).andReturn("target"); in testSetUp()
143 EasyMock.expect(mMockIDevice.isEmulator()).andReturn(true); in testSetUp_noAvdName()
153 EasyMock.expect(mMockIDevice.getAvdName()).andReturn("").times(2); in testSetUp_noAvdName()
178 EasyMock.expect(mMockIDevice.isEmulator()).andReturn(true); in testSetUp_failedBoot()
256 mMockIDevice); in replayMocks()
261 mMockIDevice); in verifyMocks()
DRunCommandTargetPreparerTest.java151 IDevice mMockIDevice = EasyMock.createMock(IDevice.class); in testBgCmd() local
152 EasyMock.expect(mMockIDevice.getSerialNumber()).andReturn("SERIAL").anyTimes(); in testBgCmd()
156 EasyMock.expect(mMockDevice.getIDevice()).andReturn(mMockIDevice).atLeastOnce(); in testBgCmd()
158 mMockIDevice.executeShellCommand(EasyMock.eq(command), EasyMock.same(mMockReceiver), in testBgCmd()
DDeviceSetupTest.java46 private IDevice mMockIDevice; field in DeviceSetupTest
59 mMockIDevice = EasyMock.createMock(IDevice.class); in setUp()
62 EasyMock.expect(mMockDevice.getIDevice()).andStubReturn(mMockIDevice); in setUp()
926 EasyMock.replay(mMockDevice, mMockIDevice); in testSetup_syncData()
928 EasyMock.verify(mMockDevice, mMockIDevice); in testSetup_syncData()
938 EasyMock.replay(mMockDevice, mMockIDevice); in testSetup_syncDataFails()
1187 EasyMock.expect(mMockDevice.getIDevice()).andReturn(mMockIDevice); in doSyncDataExpectations()
1189 EasyMock.expect(mMockIDevice.getMountPoint(IDevice.MNT_EXTERNAL_STORAGE)).andReturn( in doSyncDataExpectations()
/tools/tradefederation/core/tests/src/com/android/tradefed/testtype/
DVersionedTfLauncherTest.java73 private IDevice mMockIDevice; field in VersionedTfLauncherTest
108 mMockIDevice = EasyMock.createMock(IDevice.class); in testRun_singleDevice()
146 EasyMock.expect(mMockTestDevice.getIDevice()).andReturn(mMockIDevice).times(2); in testRun_singleDevice()
168 mMockIDevice = new NullDevice("null-device-1"); in testRun_nullDevice()
202 EasyMock.expect(mMockTestDevice.getIDevice()).andReturn(mMockIDevice).times(1); in testRun_nullDevice()
289 mMockIDevice = EasyMock.createMock(IDevice.class); in testGetTestShard()
328 EasyMock.expect(mMockTestDevice.getIDevice()).andReturn(mMockIDevice).times(2); in testGetTestShard()
DAndroidJUnitTestTest.java53 private IDevice mMockIDevice; field in AndroidJUnitTestTest
62 mMockIDevice = EasyMock.createMock(IDevice.class); in setUp()
64 EasyMock.expect(mMockTestDevice.getIDevice()).andStubReturn(mMockIDevice); in setUp()
DInstrumentationTestTest.java82 @Mock IDevice mMockIDevice; field in InstrumentationTestTest
110 doReturn(mMockIDevice).when(mMockTestDevice).getIDevice(); in setUp()
184 mInstrumentationTest.createRemoteAndroidTestRunner("", "", mMockIDevice); in testRun_hiddenApiCheck()