0009_input: add ecore_wl2_input_name_get() TCs 86/313686/1
authorJihoon Kim <jihoon48.kim@samsung.com>
Mon, 1 Jul 2024 04:10:07 +0000 (13:10 +0900)
committerJihoon Kim <jihoon48.kim@samsung.com>
Mon, 1 Jul 2024 04:10:07 +0000 (13:10 +0900)
Change-Id: Iadb316c7b7a8a26bafccea702ec55b8bd98301bb
Signed-off-by: Jihoon Kim <jihoon48.kim@samsung.com>
src/testcase/0009_input.cpp

index 8b63b05240c75fb23ab544e06ddf798dea2b9063..e6821439cc163c627ec2e033c4dc93ea38f5b837 100644 (file)
@@ -638,6 +638,30 @@ TEST_F(etTestInput, input_cursor_size_set_null_input)
    ASSERT_EQ(etRunner::get().verifyTC(testCaseName, testName), EINA_TRUE);
 }
 
+TEST_F(etTestInput, input_name_get)
+{
+   Ecore_Wl2_Display *display = NULL;
+   Ecore_Wl2_Input *input = NULL;
+   Eina_Stringshare *name = NULL;
+
+   display = ecore_wl2_connected_display_get(NULL);
+   EINA_SAFETY_ON_NULL_RETURN(display);
+
+   input = ecore_wl2_input_default_input_get(display);
+   EINA_SAFETY_ON_NULL_RETURN(input);
+
+   name = ecore_wl2_input_name_get(input);
+   ASSERT_NE(name, nullptr);
+}
+
+TEST_F(etTestInput, input_name_get_null_input)
+{
+   Eina_Stringshare *name = NULL;
+
+   name = ecore_wl2_input_name_get(NULL);
+   ASSERT_EQ(name, nullptr);
+}
+
 TEST_F(etTestInput, keyboard_get)
 {
    Ecore_Wl2_Window *wlwin = NULL;