From 1f7f6599516b4612d67901c1a759aa61763349e7 Mon Sep 17 00:00:00 2001 From: Johan Hedberg Date: Fri, 18 Jan 2013 12:58:33 +0200 Subject: [PATCH] tools: Add another invalid params test for mgmt_load_link_keys --- tools/mgmt-tester.c | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/tools/mgmt-tester.c b/tools/mgmt-tester.c index aee7d1790..d7fae3579 100644 --- a/tools/mgmt-tester.c +++ b/tools/mgmt-tester.c @@ -919,6 +919,7 @@ static const struct generic_data add_uuid32_test_1 = { static const char load_link_keys_valid_param_1[] = { 0x00, 0x00, 0x00 }; static const char load_link_keys_valid_param_2[] = { 0x01, 0x00, 0x00 }; static const char load_link_keys_invalid_param_1[] = { 0x02, 0x00, 0x00 }; +static const char load_link_keys_invalid_param_2[] = { 0x00, 0x01, 0x00 }; static const struct generic_data load_link_keys_success_test_1 = { .send_opcode = MGMT_OP_LOAD_LINK_KEYS, @@ -941,6 +942,13 @@ static const struct generic_data load_link_keys_invalid_params_test_1 = { .expect_status = MGMT_STATUS_INVALID_PARAMS, }; +static const struct generic_data load_link_keys_invalid_params_test_2 = { + .send_opcode = MGMT_OP_LOAD_LINK_KEYS, + .send_param = load_link_keys_invalid_param_2, + .send_len = sizeof(load_link_keys_invalid_param_2), + .expect_status = MGMT_STATUS_INVALID_PARAMS, +}; + static void powered_delay(void *user_data) { tester_setup_complete(); @@ -1455,6 +1463,9 @@ int main(int argc, char *argv[]) test_bredr("Load Link Keys - Invalid Parameters 1", &load_link_keys_invalid_params_test_1, NULL, test_command_generic); + test_bredr("Load Link Keys - Invalid Parameters 2", + &load_link_keys_invalid_params_test_2, NULL, + test_command_generic); return tester_run(); } -- 2.47.3