Home
last modified time | relevance | path

Searched refs:expectedState (Results 1 – 21 of 21) sorted by relevance

/packages/services/Telecomm/tests/src/com/android/server/telecom/tests/
DCallAudioRouteControllerTest.java225 CallAudioState expectedState = new CallAudioState(false, CallAudioState.ROUTE_EARPIECE, in testNormalCallRouteToEarpiece() local
229 any(CallAudioState.class), eq(expectedState)); in testNormalCallRouteToEarpiece()
258 CallAudioState expectedState = new CallAudioState(false, CallAudioState.ROUTE_SPEAKER, in testVideoCallRouteToSpeaker() local
262 any(CallAudioState.class), eq(expectedState)); in testVideoCallRouteToSpeaker()
265 expectedState = new CallAudioState(false, CallAudioState.ROUTE_WIRED_HEADSET, in testVideoCallRouteToSpeaker()
272 any(CallAudioState.class), eq(expectedState)); in testVideoCallRouteToSpeaker()
282 CallAudioState expectedState = new CallAudioState(false, CallAudioState.ROUTE_BLUETOOTH, in testActiveDeactivateBluetoothDevice() local
288 any(CallAudioState.class), eq(expectedState)); in testActiveDeactivateBluetoothDevice()
290 expectedState = new CallAudioState(false, CallAudioState.ROUTE_EARPIECE, in testActiveDeactivateBluetoothDevice()
296 any(CallAudioState.class), eq(expectedState)); in testActiveDeactivateBluetoothDevice()
[all …]
DCallAudioRouteStateMachineTest.java998 CallAudioState expectedState = new CallAudioState(false, CallAudioState.ROUTE_EARPIECE, in testInitializationWithEarpieceNoHeadsetNoBluetooth() local
1000 initializationTestHelper(expectedState, CallAudioRouteStateMachine.EARPIECE_FORCE_ENABLED); in testInitializationWithEarpieceNoHeadsetNoBluetooth()
1006 CallAudioState expectedState = new CallAudioState(false, CallAudioState.ROUTE_WIRED_HEADSET, in testInitializationWithEarpieceAndHeadsetNoBluetooth() local
1008 initializationTestHelper(expectedState, CallAudioRouteStateMachine.EARPIECE_FORCE_ENABLED); in testInitializationWithEarpieceAndHeadsetNoBluetooth()
1014 CallAudioState expectedState = new CallAudioState(false, CallAudioState.ROUTE_BLUETOOTH, in testInitializationWithEarpieceAndHeadsetAndBluetooth() local
1017 initializationTestHelper(expectedState, CallAudioRouteStateMachine.EARPIECE_FORCE_ENABLED); in testInitializationWithEarpieceAndHeadsetAndBluetooth()
1023 CallAudioState expectedState = new CallAudioState(false, CallAudioState.ROUTE_BLUETOOTH, in testInitializationWithEarpieceAndBluetoothNoHeadset() local
1026 initializationTestHelper(expectedState, CallAudioRouteStateMachine.EARPIECE_FORCE_ENABLED); in testInitializationWithEarpieceAndBluetoothNoHeadset()
1032 CallAudioState expectedState = new CallAudioState(false, CallAudioState.ROUTE_SPEAKER, in testInitializationWithNoEarpieceNoHeadsetNoBluetooth() local
1034 initializationTestHelper(expectedState, CallAudioRouteStateMachine.EARPIECE_FORCE_DISABLED); in testInitializationWithNoEarpieceNoHeadsetNoBluetooth()
[all …]
DCallAudioRouteTransitionTests.java359 CallAudioState expectedState = new CallAudioState(false, mParams.expectedRoute, in testActiveTransition() local
362 verifyNewSystemCallAudioState(initState, expectedState); in testActiveTransition()
414 CallAudioState expectedState = new CallAudioState(false, expectedRoute, in testQuiescentTransition() local
417 assertEquals(expectedState, stateMachine.getCurrentCallAudioState()); in testQuiescentTransition()
/packages/modules/Permission/PermissionController/tests/mocking/src/com/android/permissioncontroller/tests/mocking/permission/utils/
DGrantRevokeTests.kt284 expectedState: Map<String, Pair<Boolean, Int>> in assertGroupPermState()
288 assertThat(perms.keys).isEqualTo(expectedState.keys) in assertGroupPermState()
290 for ((permName, state) in expectedState) { in assertGroupPermState()
422 val expectedState = mutableMapOf(FG_PERM_NAME to (true to newFlags)) in grantOnePermTest() constant
423 assertGroupPermState(newGroup, expectedState) in grantOnePermTest()
463 val expectedState = in grantTwoPermTest() constant
465 assertGroupPermState(newGroup, expectedState) in grantTwoPermTest()
493 val expectedState = mutableMapOf(FG_PERM_NAME_NO_APP_OP to (true to newFlags)) in grantNoAppOpPerm() constant
494 assertGroupPermState(newGroup, expectedState) in grantNoAppOpPerm()
523 val expectedState = in grantBgPermTest() constant
[all …]
/packages/modules/Permission/tests/cts/permissionpolicy/src/android/permissionpolicy/cts/
DRestrictedStoragePermissionSharedUidTest.java240 StorageState expectedState; in checkExceptedStorageStateForAppsSharingUid() local
243 expectedState = DENIED; in checkExceptedStorageStateForAppsSharingUid()
245 expectedState = ISOLATED; in checkExceptedStorageStateForAppsSharingUid()
248 expectedState = NON_ISOLATED; in checkExceptedStorageStateForAppsSharingUid()
250 expectedState = ISOLATED; in checkExceptedStorageStateForAppsSharingUid()
253 Log.i(LOG_TAG, "Expected state=" + expectedState); in checkExceptedStorageStateForAppsSharingUid()
255 app1.assertStoragePermGranted(expectedState != DENIED); in checkExceptedStorageStateForAppsSharingUid()
256 app2.assertStoragePermGranted(expectedState != DENIED); in checkExceptedStorageStateForAppsSharingUid()
258 if (expectedState != DENIED) { in checkExceptedStorageStateForAppsSharingUid()
259 app1.assertHasNotIsolatedStorage(expectedState == NON_ISOLATED); in checkExceptedStorageStateForAppsSharingUid()
[all …]
/packages/services/Car/tests/carservice_test/src/com/android/car/power/
DCarPowerManagementTest.java675 private void assertResponse(int expectedState, int expectedParam, boolean checkParam) in assertResponse() argument
678 DEFAULT_WAIT_TIMEOUT_MS, expectedState); in assertResponse()
680 assertEquals(expectedState, last[0]); in assertResponse()
687 private void assertResponseTransient(int expectedState, int expectedParam, boolean checkParam) in assertResponseTransient() argument
690 DEFAULT_WAIT_TIMEOUT_MS, expectedState); in assertResponseTransient()
692 if (expectedState != aState[0]) continue; in assertResponseTransient()
698 fail("Did not find expected state: " + expectedState); in assertResponseTransient()
778 boolean waitForDisplayState(int displayId, boolean expectedState) throws Exception { in waitForDisplayState() argument
783 if (expectedState == enabled) { in waitForDisplayState()
788 return expectedState == enabled; in waitForDisplayState()
[all …]
/packages/apps/Nfc/testutils/src/com/android/nfc/utils/
DNfcSnippet.java91 int expectedState = enable ? NfcAdapter.STATE_ON : NfcAdapter.STATE_OFF; in setNfcState() local
92 if (nfcAdapter.getAdapterState() == expectedState) { in setNfcState()
93 Log.i(TAG, "toggleNfc: Already in expected state: " + expectedState); in setNfcState()
104 if (expectedState == state) countDownLatch.countDown(); in setNfcState()
/packages/modules/IPsec/tests/iketests/src/java/com/android/internal/net/eap/statemachine/
DEapTtlsHandshakeStateTest.java292 Class<? extends EapMethodState> expectedState) in testHandshake() argument
300 expectedState); in testHandshake()
319 Class<? extends EapMethodState> expectedState) in testHandshake() argument
328 assertTrue(expectedState.isInstance(mStateMachine.getState())); in testHandshake()
DEapTtlsTunnelStateTest.java336 Class<? extends EapMethodState> expectedState) in processMessageAndVerifyEapResponse() argument
349 assertTrue(expectedState.isInstance(mStateMachine.getState())); in processMessageAndVerifyEapResponse()
/packages/apps/Messaging/tests/src/com/android/messaging/datamodel/action/
DActionTestHelpers.java106 protected void updateState(final Action action, final int expectedState, in updateState() argument
109 super.updateState(action, expectedState, state); in updateState()
/packages/modules/Connectivity/tests/cts/net/src/android/net/cts/
DNetworkStatsManagerTest.java753 int expectedState, long maxUnexpected) { in assertAlmostNoUnexpectedTraffic() argument
764 maxUnexpected, tagToString(expectedTag), stateToString(expectedState), in assertAlmostNoUnexpectedTraffic()
932 Integer expectedState) { in getTotalAndAssertNotEmpty() argument
943 if (expectedState != null) assertEquals(bucket.getState(), (int) expectedState); in getTotalAndAssertNotEmpty()
956 Process.myUid(), tagToString(expectedTag), stateToString(expectedState)); in getTotalAndAssertNotEmpty()
/packages/modules/Connectivity/tests/cts/hostside-network-policy/app/src/com/android/cts/netpolicy/hostside/
DAbstractRestrictBackgroundNetworkTestCase.java554 final State expectedState; in checkForAvailabilityInNetworkCheckResult() local
557 expectedState = State.CONNECTED; in checkForAvailabilityInNetworkCheckResult()
560 expectedState = State.DISCONNECTED; in checkForAvailabilityInNetworkCheckResult()
568 if (expectedState != state || expectedDetailedState != detailedState) { in checkForAvailabilityInNetworkCheckResult()
570 expectedState, expectedDetailedState, state, detailedState)); in checkForAvailabilityInNetworkCheckResult()
/packages/apps/Launcher3/tests/tapl/com/android/launcher3/tapl/
DLauncherInstrumentation.java1633 void runToState(Runnable command, int expectedState, boolean requireEvent, String actionName) { in runToState() argument
1637 + expectedState + " actionName: " + actionName + "requireEvent: true"); in runToState()
1638 runToState(command, expectedState, actionName); in runToState()
1645 public void runToState(Runnable command, int expectedState, String actionName) { in runToState() argument
1649 event -> isSwitchToStateEvent(event, expectedState, actualEvents), in runToState()
1651 + TestProtocol.stateOrdinalToString(expectedState) in runToState()
1657 AccessibilityEvent event, int expectedState, List<Integer> actualEvents) { in isSwitchToStateEvent() argument
1663 return actualState == expectedState; in isSwitchToStateEvent()
1666 void swipeToState(int startX, int startY, int endX, int endY, int steps, int expectedState, in swipeToState() argument
1670 expectedState, in swipeToState() local
/packages/modules/IPsec/tests/iketests/src/java/com/android/internal/net/ipsec/ike/
DChildSessionStateMachineTest.java1230 Class<?> expectedState, in verifyRekeyChildLocalCreateHandlesResponse() argument
1236 expectedState, isMobikeRekey, localAddress, remoteAddress, mMockUdpEncapSocket); in verifyRekeyChildLocalCreateHandlesResponse()
1240 Class<?> expectedState, in verifyRekeyChildLocalCreateHandlesResponse() argument
1246 assertTrue(expectedState.isInstance(mChildSessionStateMachine.getCurrentState())); in verifyRekeyChildLocalCreateHandlesResponse()
1361 Class<T> exceptionClass, IState expectedState, int expectedErrorCode) { in verifyIkeSessionFatalErrorAndSendOutboundIkeDeletePayload() argument
1371 IkeMetrics.IKE_SESSION_TYPE_CHILD, getStateCode(expectedState), expectedErrorCode); in verifyIkeSessionFatalErrorAndSendOutboundIkeDeletePayload()
DIkeSessionStateMachineTest.java1610 private void verifyFireCallbackOnDnsFailure(IkeSessionCallback callback, IState expectedState) { in verifyFireCallbackOnDnsFailure() argument
1616 getStateCode(expectedState), IkeMetrics.IKE_ERROR_IO_DNS_FAILURE); in verifyFireCallbackOnDnsFailure()
1621 verifyIkeMetricsLogged(getStateCode(expectedState), IkeMetrics.IKE_ERROR_INTERNAL); in verifyFireCallbackOnDnsFailure()
5303 private void verifyIkeDeleteRequestHandled(IState expectedState) throws Exception { in verifyIkeDeleteRequestHandled() argument
5322 verifyNotifyUserCloseSession(expectedState); in verifyIkeDeleteRequestHandled()
6787 IkeNetworkCallbackBase callback, IkeSaRecord rekeySaRecord, State expectedState) in verifySetNetwork() argument
6789 verifySetNetwork(callback, rekeySaRecord, expectedState, true /* isIpv4 */); in verifySetNetwork()
6795 State expectedState, in verifySetNetwork() argument
6827 assertEquals(expectedState, mIkeSessionStateMachine.getCurrentState()); in verifySetNetwork()
/packages/services/Car/tests/carservice_unit_test/src/com/android/car/hardware/power/
DCarPowerManagerUnitTest.java484 private void assertStateReceived(int expectedState, int expectedParam) throws Exception { in assertStateReceived() argument
486 assertThat(state).asList().containsExactly(expectedState, expectedParam).inOrder(); in assertStateReceived()
/packages/apps/DeskClock/tests/src/com/android/deskclock/timer/
DTimerFragmentTest.java675 private void assertStateEquals(Timer.State expectedState, int index) { in assertStateEquals() argument
679 assertSame(expectedState, actualState); in assertStateEquals()
/packages/services/Car/tests/carservice_unit_test/src/com/android/car/power/
DCarPowerManagementServiceUnitTest.java2769 private void assertStateReceived(int expectedState, int expectedParam) throws Exception { in assertStateReceived() argument
2771 assertThat(state[0]).isEqualTo(expectedState); in assertStateReceived()
3189 private void waitForAllDisplaysState(boolean expectedState, long timeoutMs) in waitForAllDisplaysState() argument
3197 if (expectedState) { in waitForAllDisplaysState()
3205 private void waitForDisplayState(int displayId, boolean expectedState, long timeoutMs) in waitForDisplayState() argument
3211 if (enabled == expectedState) { in waitForDisplayState()
/packages/modules/Bluetooth/android/app/tests/unit/src/com/android/bluetooth/hfpclient/
DHeadsetClientStateMachineTest.java971 private int verifyVoiceRecognitionBroadcast(int expectedBroadcastIndex, int expectedState) {
982 Assert.assertEquals(expectedState, state);
/packages/modules/Connectivity/Tethering/tests/unit/src/com/android/networkstack/tethering/
DTetheringTest.java1001 final int expectedState = isLocalOnly ? IFACE_IP_MODE_LOCAL_ONLY : IFACE_IP_MODE_TETHERED; in verifyStartHotspot() local
1002 verify(mWifiManager).updateInterfaceIpState(TEST_WLAN_IFNAME, expectedState); in verifyStartHotspot()
/packages/providers/MediaProvider/src/com/android/providers/media/
DMediaProvider.java1530 final int expectedState = isEnabled in setComponentEnabledSetting() local
1535 + componentStateToString(expectedState)); in setComponentEnabledSetting()
1537 getContext().getPackageManager().setComponentEnabledSetting(componentName, expectedState, in setComponentEnabledSetting()