Diff between e8fc8d87302aa7e53ca2ca4b3366e35dfba7303f and 962a69ec72d4a2329d2eaaf535f132233793e409

Changed Files

File Additions Deletions Status
unit/test-avdtp.c +15 -1 modified

Full Patch

diff --git a/unit/test-avdtp.c b/unit/test-avdtp.c
index f6c7fb7..f05a1b1 100644
--- a/unit/test-avdtp.c
+++ b/unit/test-avdtp.c
@@ -384,7 +384,8 @@ static void sep_start_cfm(struct avdtp *session, struct avdtp_local_sep *sep,
 	struct context *context = user_data;
 	int ret;
 
-	if (g_str_equal(context->data->test_name, "/TP/SIG/SMG/BI-19-C")) {
+	if (g_str_equal(context->data->test_name, "/TP/SIG/SMG/BI-19-C") ||
+		g_str_equal(context->data->test_name, "/TP/SIG/SMG/BI-22-C")) {
 		g_assert(err != NULL);
 		g_assert_cmpint(avdtp_error_error_code(err), ==, 0x31);
 		context_quit(context);
@@ -898,6 +899,19 @@ int main(int argc, char *argv[])
 			raw_pdu(0x32, 0x06),
 			raw_pdu(0x40, 0x07, 0x04),
 			raw_pdu(0x43, 0x07, 0x04, 0xc0));
+	define_test("/TP/SIG/SMG/BI-22-C", test_client,
+			raw_pdu(0xa0, 0x01),
+			raw_pdu(0xa2, 0x01, 0x04, 0x00),
+			raw_pdu(0xb0, 0x02, 0x04),
+			raw_pdu(0xb2, 0x02, 0x01, 0x00, 0x07, 0x06, 0x00, 0x00,
+				0xff, 0xff, 0x02, 0x40),
+			raw_pdu(0xc0, 0x03, 0x04, 0x04, 0x01, 0x00, 0x07, 0x06,
+				0x00, 0x00, 0x21, 0x02, 0x02, 0x20),
+			raw_pdu(0xc2, 0x03),
+			raw_pdu(0xd0, 0x06, 0x04),
+			raw_pdu(0xd2, 0x06),
+			raw_pdu(0xe0, 0x07, 0x04),
+			raw_pdu(0xe3, 0x07, 0x04, 0x31));
 
 	return g_test_run();
 }