Home
last modified time | relevance | path

Searched refs:DEVICE_ID (Results 1 – 13 of 13) sorted by relevance

/frameworks/base/services/tests/servicestests/src/com/android/server/input/
DBatteryControllerTests.kt60 const val DEVICE_ID = 13 constant
80 `when`(iInputManager.inputDeviceIds).thenReturn(intArrayOf(DEVICE_ID, SECOND_DEVICE_ID)) in setup()
81 `when`(iInputManager.getInputDevice(DEVICE_ID)).thenReturn(createInputDevice(DEVICE_ID)) in setup()
111 batteryController.registerBatteryListener(DEVICE_ID, listener, PID) in testRegisterAndUnregisterBinderLifecycle()
119 batteryController.unregisterBatteryListener(DEVICE_ID, listener, PID) in testRegisterAndUnregisterBinderLifecycle()
126 batteryController.registerBatteryListener(DEVICE_ID, listener1, PID) in testOneListenerPerProcess()
132 batteryController.registerBatteryListener(DEVICE_ID, listener2, PID) in testOneListenerPerProcess()
142 batteryController.registerBatteryListener(DEVICE_ID, listener, PID) in testProcessDeathRemovesListener()
150 batteryController.registerBatteryListener(DEVICE_ID, listener, PID) in testProcessDeathRemovesListener()
156 `when`(native.getBatteryStatus(DEVICE_ID)).thenReturn(STATUS_FULL) in testRegisteringListenerNotifiesStateImmediately()
[all …]
/frameworks/base/core/tests/coretests/src/android/hardware/input/
DInputDeviceSensorManagerTest.java72 private static final int DEVICE_ID = 1000; field in InputDeviceSensorManagerTest
93 when(mIInputManagerMock.getInputDeviceIds()).thenReturn(new int[]{DEVICE_ID}); in setUp()
95 when(mIInputManagerMock.getInputDevice(eq(DEVICE_ID))).thenReturn( in setUp()
96 createInputDeviceWithSensor(DEVICE_ID)); in setUp()
98 when(mIInputManagerMock.getSensorList(eq(DEVICE_ID))).thenReturn(new InputSensorInfo[] { in setUp()
99 createInputSensorInfo(DEVICE_ID, Sensor.TYPE_ACCELEROMETER), in setUp()
100 createInputSensorInfo(DEVICE_ID, Sensor.TYPE_GYROSCOPE)}); in setUp()
102 when(mIInputManagerMock.enableSensor(eq(DEVICE_ID), anyInt(), anyInt(), anyInt())) in setUp()
183 verify(mIInputManagerMock).getSensorList(eq(DEVICE_ID)); in getInputDeviceSensors_withExpectedType()
185 assertEquals(DEVICE_ID, accelList.get(0).getId()); in getInputDeviceSensors_withExpectedType()
[all …]
DInputDeviceLightsManagerTest.java69 private static final int DEVICE_ID = 1000; field in InputDeviceLightsManagerTest
80 when(mIInputManagerMock.getInputDeviceIds()).thenReturn(new int[]{DEVICE_ID}); in setUp()
82 when(mIInputManagerMock.getInputDevice(eq(DEVICE_ID))).thenReturn( in setUp()
83 createInputDevice(DEVICE_ID)); in setUp()
96 }).when(mIInputManagerMock).setLightStates(eq(DEVICE_ID), in setUp()
105 }).when(mIInputManagerMock).getLightState(eq(DEVICE_ID), anyInt()); in setUp()
123 when(mIInputManagerMock.getLights(eq(DEVICE_ID))).thenReturn( in mockLights()
129 InputDevice device = mInputManager.getInputDevice(DEVICE_ID); in testGetInputDeviceLights()
144 verify(mIInputManagerMock).getLights(eq(DEVICE_ID)); in testGetInputDeviceLights()
150 InputDevice device = mInputManager.getInputDevice(DEVICE_ID); in testControlMultipleLights()
[all …]
/frameworks/base/core/tests/coretests/src/android/view/
DKeyEventTest.java47 private static final int DEVICE_ID = 0; field in KeyEventTest
58 METASTATE, DEVICE_ID, SCAN_CODE, FLAGS, SOURCE, CHARACTERS); in testObtain()
65 assertEquals(DEVICE_ID, keyEvent.getDeviceId()); in testObtain()
76 METASTATE, DEVICE_ID, SCAN_CODE, FLAGS, SOURCE, CHARACTERS); in testObtainFromKeyEvent()
85 METASTATE, DEVICE_ID, SCAN_CODE, FLAGS, SOURCE, displayId, CHARACTERS); in testObtainWithDisplayId()
92 assertEquals(DEVICE_ID, keyEvent.getDeviceId()); in testObtainWithDisplayId()
111 METASTATE, DEVICE_ID, SCAN_CODE, FLAGS, SOURCE, CHARACTERS); in testObtainGeneratesUniqueId()
133 METASTATE, DEVICE_ID, SCAN_CODE, FLAGS, SOURCE, CHARACTERS); in testObtainGeneratesIdWithRightSource()
168 DEVICE_ID, SCAN_CODE, FLAGS, SOURCE, INVALID_DISPLAY, CHARACTERS); in createKey()
DVerifiedKeyEventTest.kt41 assertEquals(DEVICE_ID, event.deviceId) in testConstructor()
131 private const val DEVICE_ID = 0 constant
145 return VerifiedKeyEvent(DEVICE_ID, EVENT_TIME_NANOS, SOURCE, DISPLAY_ID, ACTION, in createVerifiedKeyEvent()
DVerifiedMotionEventTest.kt46 assertEquals(DEVICE_ID, event.deviceId) in testConstructor()
153 private const val DEVICE_ID = 0 constant
166 return VerifiedMotionEvent(DEVICE_ID, EVENT_TIME_NANOS, SOURCE, DISPLAY_ID, in createVerifiedMotionEvent()
/frameworks/base/tests/Input/src/com/android/test/input/
DInputDeviceTest.java34 private static final int DEVICE_ID = 1000; field in InputDeviceTest
72 new InputDevice(DEVICE_ID, 0 /* generation */, 0 /* controllerNumber */, "name", in assertInputDeviceParcelUnparcel()
95 final KeyCharacterMap keyCharacterMap = KeyCharacterMap.obtainEmptyMap(DEVICE_ID); in testParcelUnparcelInputDevice_EmptyCharacterMap()
/frameworks/native/services/inputflinger/benchmarks/
DInputDispatcher_benchmarks.cpp34 constexpr int32_t DEVICE_ID = 1; variable
222 event.initialize(IInputConstants::INVALID_INPUT_EVENT_ID, DEVICE_ID, AINPUT_SOURCE_TOUCHSCREEN, in generateMotionEvent()
249 DEVICE_ID, AINPUT_SOURCE_TOUCHSCREEN, ADISPLAY_ID_DEFAULT, in generateMotionArgs()
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/media/controls/pipeline/
DMediaDeviceManagerTest.kt73 private const val DEVICE_ID = "DEVICE_ID" constant
508 whenever(device.id).thenReturn(DEVICE_ID) in deviceIdChanged_informListener()
515 val updatedId = DEVICE_ID + "_new" in deviceIdChanged_informListener()
527 assertThat(firstDevice.id).isEqualTo(DEVICE_ID) in deviceIdChanged_informListener()
536 whenever(device.id).thenReturn(DEVICE_ID) in deviceNameChanged_informListener()
565 whenever(device.id).thenReturn(DEVICE_ID) in deviceIconChanged_doesNotCallListener()
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/temporarydisplay/chipbar/
DChipbarCoordinatorTest.kt430 underTest.removeView(DEVICE_ID, "TestReason") in displayView_loadingThenHideView_animationStopped()
574 underTest.removeView(DEVICE_ID, "test reason") in displayViewThenImmediateRemoval_viewStillRemoved()
593 underTest.removeView(DEVICE_ID, "test reason") in removeView_animationFailure_viewStillRemoved()
696 id = DEVICE_ID, in createChipbarInfo()
744 private const val DEVICE_ID = "id" constant
/frameworks/native/services/inputflinger/tests/
DInputReader_test.cpp2665 static const int32_t DEVICE_ID; member in android::InputDeviceTest
2686 mDevice = std::make_shared<InputDevice>(mReader->getContext(), DEVICE_ID, DEVICE_GENERATION, in SetUp()
2701 const int32_t InputDeviceTest::DEVICE_ID = END_RESERVED_ID + 1000; member in android::InputDeviceTest
2709 ASSERT_EQ(DEVICE_ID, mDevice->getId()); in TEST_F()
2729 ASSERT_EQ(DEVICE_ID, resetArgs.deviceId); in TEST_F()
2736 ASSERT_EQ(DEVICE_ID, info.getId()); in TEST_F()
2798 ASSERT_EQ(DEVICE_ID, resetArgs.deviceId); in TEST_F()
2805 ASSERT_EQ(DEVICE_ID, info.getId()); in TEST_F()
2965 static const int32_t DEVICE_ID; member in android::InputMapperTest
2983 mDevice = newDevice(DEVICE_ID, DEVICE_NAME, DEVICE_LOCATION, EVENTHUB_ID, classes); in SetUp()
[all …]
DUnwantedInteractionBlocker_test.cpp32 constexpr int32_t DEVICE_ID = 3; variable
105 NotifyMotionArgs args(/* id */ 0, eventTime, 0 /*readTime*/, DEVICE_ID, in generateMotionArgs()
121 info.initialize(DEVICE_ID, /*generation*/ 1, /*controllerNumber*/ 1, identifier, "alias", in generateTestDeviceInfo()
494 NotifyDeviceResetArgs args(1 /*sequenceNum*/, 2 /*eventTime*/, DEVICE_ID); in TEST_F()
514 NotifyDeviceResetArgs resetArgs(1 /*sequenceNum*/, 3 /*eventTime*/, DEVICE_ID); in TEST_F()
721 NotifyDeviceResetArgs resetArgs(1 /*sequenceNum*/, 3 /*eventTime*/, DEVICE_ID); in TEST_F()
DInputDispatcher_test.cpp51 static constexpr int32_t DEVICE_ID = 1; variable
92 event.initialize(InputEvent::nextId(), DEVICE_ID, AINPUT_SOURCE_KEYBOARD, ADISPLAY_ID_NONE, in getTestKeyEvent()
562 event.initialize(InputEvent::nextId(), DEVICE_ID, AINPUT_SOURCE_KEYBOARD, ADISPLAY_ID_NONE, in TEST_F()
572 event.initialize(InputEvent::nextId(), DEVICE_ID, AINPUT_SOURCE_KEYBOARD, ADISPLAY_ID_NONE, in TEST_F()
599 event.initialize(InputEvent::nextId(), DEVICE_ID, source, DISPLAY_ID, INVALID_HMAC, in TEST_F()
611 event.initialize(InputEvent::nextId(), DEVICE_ID, source, DISPLAY_ID, INVALID_HMAC, in TEST_F()
622 event.initialize(InputEvent::nextId(), DEVICE_ID, source, DISPLAY_ID, INVALID_HMAC, in TEST_F()
635 event.initialize(InputEvent::nextId(), DEVICE_ID, source, DISPLAY_ID, INVALID_HMAC, in TEST_F()
646 event.initialize(InputEvent::nextId(), DEVICE_ID, source, DISPLAY_ID, INVALID_HMAC, in TEST_F()
659 event.initialize(InputEvent::nextId(), DEVICE_ID, source, DISPLAY_ID, INVALID_HMAC, in TEST_F()
[all …]