Diff between b16ae734a2b95380bd95e17bf0b5c7f05e73c9ce and c5ca05a3930f73722c9a76b7a98239ef9f38447c

Changed Files

File Additions Deletions Status
tools/mgmt-tester.c +21 -0 modified

Full Patch

diff --git a/tools/mgmt-tester.c b/tools/mgmt-tester.c
index 46b088c..9b71156 100644
--- a/tools/mgmt-tester.c
+++ b/tools/mgmt-tester.c
@@ -3665,6 +3665,24 @@ static const struct generic_data add_device_fail_3 = {
 	.expect_status = MGMT_STATUS_INVALID_PARAMS,
 };
 
+static const uint8_t add_device_nval_4[] = {
+					0x12, 0x34, 0x56, 0x78, 0x9a, 0xbc,
+					0x02,
+					0x02,
+};
+static const uint8_t add_device_rsp_4[] =  {
+					0x12, 0x34, 0x56, 0x78, 0x9a, 0xbc,
+					0x02,
+};
+static const struct generic_data add_device_fail_4 = {
+	.send_opcode = MGMT_OP_ADD_DEVICE,
+	.send_param = add_device_nval_4,
+	.send_len = sizeof(add_device_nval_4),
+	.expect_param = add_device_rsp_4,
+	.expect_len = sizeof(add_device_rsp_4),
+	.expect_status = MGMT_STATUS_INVALID_PARAMS,
+};
+
 static const uint8_t add_device_success_param_1[] = {
 					0x12, 0x34, 0x56, 0x78, 0x9a, 0xbc,
 					0x00,
@@ -6696,6 +6714,9 @@ int main(int argc, char *argv[])
 	test_bredrle("Add Device - Invalid Params 3",
 				&add_device_fail_3,
 				NULL, test_command_generic);
+	test_bredrle("Add Device - Invalid Params 4",
+				&add_device_fail_4,
+				NULL, test_command_generic);
 	test_bredrle("Add Device - Success 1",
 				&add_device_success_1,
 				NULL, test_command_generic);