[PATCH BlueZ 5/8] unit/test-uhid: Add /uhid/command/input test

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



From: Luiz Augusto von Dentz <luiz.von.dentz@xxxxxxxxx>

---
 unit/test-uhid.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/unit/test-uhid.c b/unit/test-uhid.c
index b8bb3a4..cb9b05a 100644
--- a/unit/test-uhid.c
+++ b/unit/test-uhid.c
@@ -235,6 +235,10 @@ static const struct uhid_event ev_feature_answer = {
 	.type = UHID_FEATURE_ANSWER,
 };
 
+static const struct uhid_event ev_input = {
+	.type = UHID_INPUT,
+};
+
 static void test_client(gconstpointer data)
 {
 	struct context *context = create_context(data);
@@ -249,6 +253,9 @@ static void test_client(gconstpointer data)
 						"/uhid/command/feature_answer"))
 		bt_uhid_send(context->uhid, &ev_feature_answer);
 
+	if (g_str_equal(context->data->test_name, "/uhid/command/input"))
+		bt_uhid_send(context->uhid, &ev_input);
+
 	execute_context(context);
 }
 
@@ -260,6 +267,7 @@ int main(int argc, char *argv[])
 	define_test("/uhid/command/destroy", test_client, event(&ev_destroy));
 	define_test("/uhid/command/feature_answer", test_client,
 						event(&ev_feature_answer));
+	define_test("/uhid/command/input", test_client, event(&ev_input));
 
 	return g_test_run();
 }
-- 
1.9.0

--
To unsubscribe from this list: send the line "unsubscribe linux-bluetooth" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Bluez Devel]     [Linux Wireless Networking]     [Linux Wireless Personal Area Networking]     [Linux ATH6KL]     [Linux USB Devel]     [Linux Media Drivers]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [Big List of Linux Books]

  Powered by Linux