Home
last modified time | relevance | path

Searched refs:mockCallback (Results 1 – 11 of 11) sorted by relevance

/packages/modules/Wifi/service/tests/wifitests/src/com/android/server/wifi/rtt/
DRttServiceImplTest.java177 public IRttCallback mockCallback; field in RttServiceImplTest
332 mockCallback, mExtras); in testRangingFlow()
348 verify(mockCallback).onRangingResults(results.get(i).second); in testRangingFlow()
366 verifyNoMoreInteractions(mockRttControllerHal, mockMetrics, mockCallback, in testRangingFlow()
406 mockCallback, mExtras); in testRangingFlowUsingAwarePeerHandles()
437 verify(mockCallback).onRangingResults(mListCaptor.capture()); in testRangingFlowUsingAwarePeerHandles()
449 verifyNoMoreInteractions(mockRttControllerHal, mockMetrics, mockCallback, in testRangingFlowUsingAwarePeerHandles()
484 mockCallback, mExtras); in testRangingOnlyAwareAps()
525 mockCallback, mExtras); in testRangingFlowHalFailure()
532 mockCallback, mExtras); in testRangingFlowHalFailure()
[all …]
/packages/modules/Wifi/service/tests/wifitests/src/com/android/server/wifi/aware/
DWifiAwareStateManagerTest.java526 IWifiAwareEventCallback mockCallback = mock(IWifiAwareEventCallback.class); in testAwareDataPathInterfaceUpDown() local
529 mockCallback); in testAwareDataPathInterfaceUpDown()
538 mDut.connect(clientId, uid, pid, callingPackage, callingFeature, mockCallback, in testAwareDataPathInterfaceUpDown()
547 inOrder.verify(mockCallback).onConnectSuccess(clientId); in testAwareDataPathInterfaceUpDown()
573 IWifiAwareEventCallback mockCallback = mock(IWifiAwareEventCallback.class); in testDisableUsageDisablesApis() local
574 InOrder inOrder = inOrder(mMockContext, mMockNative, mockCallback); in testDisableUsageDisablesApis()
594 mDut.connect(clientId, uid, pid, callingPackage, callingFeature, mockCallback, in testDisableUsageDisablesApis()
597 inOrder.verify(mockCallback).onConnectFail(anyInt()); in testDisableUsageDisablesApis()
599 verifyNoMoreInteractions(mMockNative, mockCallback); in testDisableUsageDisablesApis()
616 IWifiAwareEventCallback mockCallback = mock(IWifiAwareEventCallback.class); in testDisableUsageFlow() local
[all …]
DWifiAwareServiceImplTest.java414 IWifiAwareDiscoverySessionCallback mockCallback = mock( in testFailOnPublishRangingWithoutRttFeature() local
417 mDut.publish(mPackageName, mFeatureId, clientId, publishConfig, mockCallback, mExtras); in testFailOnPublishRangingWithoutRttFeature()
431 IWifiAwareDiscoverySessionCallback mockCallback = mock( in testFailOnSubscribeRangingWithoutRttFeature() local
434 mDut.subscribe(mPackageName, mFeatureId, clientId, subscribeConfig, mockCallback, mExtras); in testFailOnSubscribeRangingWithoutRttFeature()
497 IWifiAwareDiscoverySessionCallback mockCallback = mock( in testPublish() local
500 mDut.publish(mPackageName, mFeatureId, clientId, publishConfig, mockCallback, mExtras); in testPublish()
502 verify(mAwareStateManagerMock).publish(clientId, publishConfig, mockCallback); in testPublish()
513 IWifiAwareDiscoverySessionCallback mockCallback = mock( in testPublishPostT() local
516 mDut.publish(mPackageName, mFeatureId, clientId, publishConfig, mockCallback, mExtras); in testPublishPostT()
518 verify(mAwareStateManagerMock).publish(clientId, publishConfig, mockCallback); in testPublishPostT()
[all …]
DWifiAwareDataPathStateManagerTest.java2044 AttachCallback mockCallback = mock(AttachCallback.class); in getSessionNetworkRequestMore() local
2048 InOrder inOrderS = inOrder(mockAwareService, mockCallback, mockSessionCallback); in getSessionNetworkRequestMore()
2050 mgr.attach(mMockLooperHandler, configRequest, mockCallback, null, false, null); in getSessionNetworkRequestMore()
2056 inOrderS.verify(mockCallback).onAttached(sessionCaptor.capture()); in getSessionNetworkRequestMore()
2128 AttachCallback mockCallback = mock(AttachCallback.class); in getDirectNetworkRequestMore() local
2130 mgr.attach(mMockLooperHandler, configRequest, mockCallback, null, false, null); in getDirectNetworkRequestMore()
2135 verify(mockCallback).onAttached(sessionCaptor.capture()); in getDirectNetworkRequestMore()
/packages/modules/Connectivity/tests/unit/java/com/android/server/connectivity/
DNetworkOfferTest.kt41 val mockCallback = mock(INetworkOfferCallback::class.java) constant in com.android.server.connectivity.NetworkOfferTest
46 val offer = NetworkOffer(score, NetworkCapabilities.Builder().build(), mockCallback, in testOfferNeededUnneeded()
51 verify(mockCallback).onNetworkNeeded(eq(request1)) in testOfferNeededUnneeded()
56 verify(mockCallback).onNetworkNeeded(eq(request2)) in testOfferNeededUnneeded()
65 verify(mockCallback).onNetworkUnneeded(eq(request1)) in testOfferNeededUnneeded()
70 verify(mockCallback).onNetworkUnneeded(eq(request2)) in testOfferNeededUnneeded()
/packages/modules/Wifi/framework/tests/src/android/net/wifi/aware/
DWifiAwareManagerTest.java91 public AttachCallback mockCallback; field in WifiAwareManagerTest
213 InOrder inOrder = inOrder(mockCallback, mockSessionCallback, mockAwareService); in testConnectFlow()
221 mDut.attach(mockCallback, mMockLooperHandler); in testConnectFlow()
226 inOrder.verify(mockCallback).onAttached(sessionCaptor.capture()); in testConnectFlow()
244 mDut.attach(mockCallback, mMockLooperHandler); in testConnectFlow()
248 verifyNoMoreInteractions(mockCallback, mockSessionCallback, mockAwareService); in testConnectFlow()
259 InOrder inOrder = inOrder(mockCallback, mockSessionCallback, mockAwareService); in testConnectFailure()
266 mDut.attach(mockCallback, mMockLooperHandler); in testConnectFailure()
271 inOrder.verify(mockCallback).onAttachFailed(); in testConnectFailure()
274 mDut.attach(mockCallback, mMockLooperHandler); in testConnectFailure()
[all …]
/packages/modules/Connectivity/tests/unit/java/com/android/server/connectivity/mdns/
DMdnsSocketClientTests.java86 @Mock private MdnsSocketClient.Callback mockCallback; field in MdnsSocketClientTests
111 mdnsClient.setCallback(mockCallback); in setup()
398 mdnsClient.setCallback(mockCallback); in testMulticastResponseReceived_useSeparateSocketForUnicast()
402 verify(mockCallback, timeout(TIMEOUT).atLeast(1)) in testMulticastResponseReceived_useSeparateSocketForUnicast()
411 verify(mockCallback, timeout(TIMEOUT).atLeastOnce()) in testMulticastResponseReceived_useSameSocketForMulticastAndUnicast()
419 mdnsClient.setCallback(mockCallback); in testFailedToParseMdnsResponse_useSeparateSocketForUnicast()
444 verify(mockCallback, timeout(TIMEOUT).atLeast(1)) in testFailedToParseMdnsResponse_useSeparateSocketForUnicast()
466 verify(mockCallback, timeout(TIMEOUT).atLeast(1)) in testFailedToParseMdnsResponse_useSameSocketForMulticastAndUnicast()
546 mdnsClient.setCallback(mockCallback); in startDiscovery_andPropagateInterfaceIndex_includesInterfaceIndex()
549 verify(mockCallback, timeout(TIMEOUT).atLeastOnce()) in startDiscovery_andPropagateInterfaceIndex_includesInterfaceIndex()
[all …]
/packages/modules/DeviceLock/tests/unittests/src/com/android/server/devicelock/
DDeviceLockServiceImplTest.java190 IGetDeviceIdCallback mockCallback = mock(IGetDeviceIdCallback.class); in getDeviceId_withIMEIType_shouldReturnIMEI() local
193 mService.getDeviceId(mockCallback, 1 << DEVICE_ID_TYPE_IMEI); in getDeviceId_withIMEIType_shouldReturnIMEI()
197 verify(mockCallback, timeout(ONE_SEC_MILLIS)).onDeviceIdReceived( in getDeviceId_withIMEIType_shouldReturnIMEI()
219 IGetDeviceIdCallback mockCallback = mock(IGetDeviceIdCallback.class); in getDeviceId_withMEIDType_shouldReturnMEID() local
222 mService.getDeviceId(mockCallback, 1 << DEVICE_ID_TYPE_MEID); in getDeviceId_withMEIDType_shouldReturnMEID()
226 verify(mockCallback, timeout(ONE_SEC_MILLIS)).onDeviceIdReceived( in getDeviceId_withMEIDType_shouldReturnMEID()
/packages/services/Car/cpp/telemetry/cartelemetryd/tests/
DTelemetryServerTest.cpp156 std::shared_ptr<MockCarTelemetryCallback> mockCallback = in TEST_F() local
158 mTelemetry->addCallback(config, mockCallback); in TEST_F()
165 EXPECT_CALL(*mockCallback, onChange(UnorderedElementsAre(101, 102))) in TEST_F()
/packages/modules/Wifi/service/tests/wifitests/src/com/android/server/wifi/
DWifiServiceImplTest.java11412 IInterfaceCreationInfoCallback.Stub mockCallback = mock( in testIsItPossibleToCreateInterfaceInvalidConditions() local
11417 WifiManager.WIFI_INTERFACE_TYPE_AP, true, mockCallback)); in testIsItPossibleToCreateInterfaceInvalidConditions()
11423 /* clearly invalid value */ 100, true, mockCallback)); in testIsItPossibleToCreateInterfaceInvalidConditions()
11431 WifiManager.WIFI_INTERFACE_TYPE_AP, false, mockCallback)); in testIsItPossibleToCreateInterfaceInvalidConditions()
11436 WifiManager.WIFI_INTERFACE_TYPE_AP, false, mockCallback)); in testIsItPossibleToCreateInterfaceInvalidConditions()
11444 WifiManager.WIFI_INTERFACE_TYPE_AP, false, mockCallback)); in testIsItPossibleToCreateInterfaceInvalidConditions()
11451 IInterfaceCreationInfoCallback.Stub mockCallback = mock( in testIsItPossibleToCreateInterface() local
11474 mockCallback); in testIsItPossibleToCreateInterface()
11476 mockCallback); in testIsItPossibleToCreateInterface()
11478 mockCallback); in testIsItPossibleToCreateInterface()
[all …]
/packages/modules/IPsec/tests/iketests/src/java/com/android/internal/net/ipsec/ike/
DIkeSessionStateMachineTest.java906 IkeConnectionController.Callback mockCallback, IkeSessionStateMachine ikeSession) { in setupIkeConnectionCtrlCbWithIkeSession() argument
912 .when(mockCallback) in setupIkeConnectionCtrlCbWithIkeSession()
920 .when(mockCallback) in setupIkeConnectionCtrlCbWithIkeSession()
928 .when(mockCallback) in setupIkeConnectionCtrlCbWithIkeSession()