diff options
Diffstat (limited to 'mojo/public/interfaces/bindings/tests/data')
232 files changed, 3247 insertions, 0 deletions
diff --git a/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_good.data b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_good.data new file mode 100644 index 0000000000..b797feaa2d --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_good.data @@ -0,0 +1,26 @@ +[dist4]message_header // num_bytes +[u4]2 // version +[u4]0 // interface ID +[u4]0 // name +[u4]0 // flags +[u4]0 // padding +[u8]0 // request_id +[dist8]payload +[dist8]payload_interface_ids +[anchr]message_header + +[anchr]payload +[dist4]method0_params // num_bytes +[u4]0 // version +[u4]1 // associated interface pointer: interface ID index +[u4]1 // associated interface pointer: version +[anchr]method0_params + +[anchr]payload_interface_ids +[dist4]interface_id_array // num_bytes +[u4]3 // num_elements : It is okay to have IDs that are not + // referred to. +[u4]4 +[u4]5 +[u4]8 +[anchr]interface_id_array diff --git a/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_good.expected b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_good.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_good.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_illegal_invalid_interface_id.data b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_illegal_invalid_interface_id.data new file mode 100644 index 0000000000..a36d8073c0 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_illegal_invalid_interface_id.data @@ -0,0 +1,24 @@ +[dist4]message_header // num_bytes +[u4]2 // version +[u4]0 // interface ID +[u4]0 // name +[u4]0 // flags +[u4]0 // padding +[u8]0 // request_id +[dist8]payload +[dist8]payload_interface_ids +[anchr]message_header + +[anchr]payload +[dist4]method0_params // num_bytes +[u4]0 // version +[u4]1 // associated interface pointer: interface ID index +[u4]1 // associated interface pointer: version +[anchr]method0_params + +[anchr]payload_interface_ids +[dist4]interface_id_array // num_bytes +[u4]2 // num_elements +[u4]3 +[u4]0xFFFFFFFF // Unexpected invalid interface ID. +[anchr]interface_id_array diff --git a/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_illegal_invalid_interface_id.expected b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_illegal_invalid_interface_id.expected new file mode 100644 index 0000000000..420b4210e2 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_illegal_invalid_interface_id.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_ILLEGAL_INTERFACE_ID diff --git a/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_illegal_master_interface_id.data b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_illegal_master_interface_id.data new file mode 100644 index 0000000000..e3fa5bb4f5 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_illegal_master_interface_id.data @@ -0,0 +1,24 @@ +[dist4]message_header // num_bytes +[u4]2 // version +[u4]0 // interface ID +[u4]0 // name +[u4]0 // flags +[u4]0 // padding +[u8]0 // request_id +[dist8]payload +[dist8]payload_interface_ids +[anchr]message_header + +[anchr]payload +[dist4]method0_params // num_bytes +[u4]0 // version +[u4]1 // associated interface pointer: interface ID index +[u4]1 // associated interface pointer: version +[anchr]method0_params + +[anchr]payload_interface_ids +[dist4]interface_id_array // num_bytes +[u4]2 // num_elements +[u4]3 +[u4]0 // Unexpected master interface ID. +[anchr]interface_id_array diff --git a/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_illegal_master_interface_id.expected b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_illegal_master_interface_id.expected new file mode 100644 index 0000000000..420b4210e2 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_illegal_master_interface_id.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_ILLEGAL_INTERFACE_ID diff --git a/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_interface_id_index_out_of_range.data b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_interface_id_index_out_of_range.data new file mode 100644 index 0000000000..f9e62015c9 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_interface_id_index_out_of_range.data @@ -0,0 +1,27 @@ +[dist4]message_header // num_bytes +[u4]2 // version +[u4]0 // interface ID +[u4]0 // name +[u4]0 // flags +[u4]0 // padding +[u8]0 // request_id +[dist8]payload +[dist8]payload_interface_ids +[anchr]message_header + +[anchr]payload +[dist4]method0_params // num_bytes +[u4]0 // version +[u4]1111 // associated interface pointer: The interface ID index + // is out of range. +[u4]1 // associated interface pointer: version +[anchr]method0_params + +[anchr]payload_interface_ids +[dist4]interface_id_array // num_bytes +[u4]3 // num_elements : It is okay to have IDs that are not + // referred to. +[u4]4 +[u4]5 +[u4]8 +[anchr]interface_id_array diff --git a/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_interface_id_index_out_of_range.expected b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_interface_id_index_out_of_range.expected new file mode 100644 index 0000000000..420b4210e2 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_interface_id_index_out_of_range.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_ILLEGAL_INTERFACE_ID diff --git a/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_unexpected_invalid_associated_interface.data b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_unexpected_invalid_associated_interface.data new file mode 100644 index 0000000000..b785ed1b48 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_unexpected_invalid_associated_interface.data @@ -0,0 +1,25 @@ +[dist4]message_header // num_bytes +[u4]2 // version +[u4]0 // interface ID +[u4]0 // name +[u4]0 // flags +[u4]0 // padding +[u8]0 // request_id +[dist8]payload +[dist8]payload_interface_ids +[anchr]message_header + +[anchr]payload +[dist4]method0_params // num_bytes +[u4]0 // version +[u4]0xFFFFFFFF // associated interface pointer: Unexpected invalid + // interface ID index. +[u4]1 // associated interface pointer: version +[anchr]method0_params + +[anchr]payload_interface_ids +[dist4]interface_id_array // num_bytes +[u4]2 // num_elements +[u4]3 +[u4]4 +[anchr]interface_id_array diff --git a/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_unexpected_invalid_associated_interface.expected b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_unexpected_invalid_associated_interface.expected new file mode 100644 index 0000000000..d8eda1f573 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd0_unexpected_invalid_associated_interface.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_INVALID_INTERFACE_ID diff --git a/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd1_good.data b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd1_good.data new file mode 100644 index 0000000000..efa21623f5 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd1_good.data @@ -0,0 +1,26 @@ +[dist4]message_header // num_bytes +[u4]2 // version +[u4]0 // interface ID +[u4]1 // name +[u4]0 // flags +[u4]0 // padding +[u8]0 // request_id +[dist8]payload +[dist8]payload_interface_ids +[anchr]message_header + +[anchr]payload +[dist4]method1_params // num_bytes +[u4]0 // version +[u4]1 // associated interface request: interface ID index +[u4]0 // padding +[anchr]method1_params + +[anchr]payload_interface_ids +[dist4]interface_id_array // num_bytes +[u4]3 // num_elements : It is okay to have IDs that are not + // referred to. +[u4]4 +[u4]5 +[u4]8 +[anchr]interface_id_array diff --git a/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd1_good.expected b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd1_good.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd1_good.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd1_unexpected_invalid_associated_request.data b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd1_unexpected_invalid_associated_request.data new file mode 100644 index 0000000000..5a66aad82d --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd1_unexpected_invalid_associated_request.data @@ -0,0 +1,27 @@ +[dist4]message_header // num_bytes +[u4]2 // version +[u4]0 // interface ID +[u4]1 // name +[u4]0 // flags +[u4]0 // padding +[u8]0 // request_id +[dist8]payload +[dist8]payload_interface_ids +[anchr]message_header + +[anchr]payload +[dist4]method1_params // num_bytes +[u4]0 // version +[u4]0xFFFFFFFF // associated interface request: Unexpected invalid + // interface ID index. +[u4]0 // padding +[anchr]method1_params + +[anchr]payload_interface_ids +[dist4]interface_id_array // num_bytes +[u4]3 // num_elements : It is okay to have IDs that are not + // referred to. +[u4]4 +[u4]5 +[u4]8 +[anchr]interface_id_array diff --git a/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd1_unexpected_invalid_associated_request.expected b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd1_unexpected_invalid_associated_request.expected new file mode 100644 index 0000000000..d8eda1f573 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd1_unexpected_invalid_associated_request.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_INVALID_INTERFACE_ID diff --git a/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd2_good.data b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd2_good.data new file mode 100644 index 0000000000..ab29603ec1 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd2_good.data @@ -0,0 +1,18 @@ +[dist4]message_header // num_bytes +[u4]2 // version +[u4]0 // interface ID +[u4]2 // name +[u4]0 // flags +[u4]0 // padding +[u8]0 // request_id +[dist8]payload +[u8]0 // payload_interface_ids: This array is a nullable field. +[anchr]message_header + +[anchr]payload +[dist4]method2_params // num_bytes +[u4]0 // version +[u4]0xFFFFFFFF // associated interface pointer: Invalid interface ID + // index. +[u4]1 // associated interface pointer: version +[anchr]method2_params diff --git a/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd2_good.expected b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd2_good.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd2_good.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd3_collided_interface_id_indices.data b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd3_collided_interface_id_indices.data new file mode 100644 index 0000000000..6cb71d374f --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd3_collided_interface_id_indices.data @@ -0,0 +1,36 @@ +[dist4]message_header // num_bytes +[u4]2 // version +[u4]0 // interface ID +[u4]3 // name +[u4]0 // flags +[u4]0 // padding +[u8]0 // request_id +[dist8]payload +[dist8]payload_interface_ids +[anchr]message_header + +[anchr]payload +[dist4]method3_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method3_params + +[anchr]param0_ptr +[dist4]associated_interface_array // num_bytes +[u4]2 // num_elements +[u4]2 // interface ID index +[u4]14 // version +[u4]2 // interface ID index: The same value as the + // one above. +[u4]18 // version +[anchr]associated_interface_array + +[anchr]payload_interface_ids +[dist4]interface_id_array // num_bytes +[u4]4 // num_elements : It is okay to have IDs that are not + // referred to. +[u4]4 +[u4]5 +[u4]8 +[u4]19 +[anchr]interface_id_array diff --git a/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd3_collided_interface_id_indices.expected b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd3_collided_interface_id_indices.expected new file mode 100644 index 0000000000..420b4210e2 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd3_collided_interface_id_indices.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_ILLEGAL_INTERFACE_ID diff --git a/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd3_good.data b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd3_good.data new file mode 100644 index 0000000000..13df01e049 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd3_good.data @@ -0,0 +1,35 @@ +[dist4]message_header // num_bytes +[u4]2 // version +[u4]0 // interface ID +[u4]3 // name +[u4]0 // flags +[u4]0 // padding +[u8]0 // request_id +[dist8]payload +[dist8]payload_interface_ids +[anchr]message_header + +[anchr]payload +[dist4]method3_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method3_params + +[anchr]param0_ptr +[dist4]associated_interface_array // num_bytes +[u4]2 // num_elements +[u4]2 // interface ID index +[u4]14 // version +[u4]3 // interface ID index +[u4]18 // version +[anchr]associated_interface_array + +[anchr]payload_interface_ids +[dist4]interface_id_array // num_bytes +[u4]4 // num_elements : It is okay to have IDs that are not + // referred to. +[u4]4 +[u4]5 +[u4]8 +[u4]19 +[anchr]interface_id_array diff --git a/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd3_good.expected b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd3_good.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd3_good.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd3_unexpected_invalid_associated_interface_in_array.data b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd3_unexpected_invalid_associated_interface_in_array.data new file mode 100644 index 0000000000..2e163be160 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd3_unexpected_invalid_associated_interface_in_array.data @@ -0,0 +1,36 @@ +[dist4]message_header // num_bytes +[u4]2 // version +[u4]0 // interface ID +[u4]3 // name +[u4]0 // flags +[u4]0 // padding +[u8]0 // request_id +[dist8]payload +[dist8]payload_interface_ids +[anchr]message_header + +[anchr]payload +[dist4]method3_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method3_params + +[anchr]param0_ptr +[dist4]associated_interface_array // num_bytes +[u4]2 // num_elements +[u4]2 // interface ID index +[u4]14 // version +[u4]0xFFFFFFFF // interface ID index: Unexpected invalid + // value. +[u4]18 // version +[anchr]associated_interface_array + +[anchr]payload_interface_ids +[dist4]interface_id_array // num_bytes +[u4]4 // num_elements : It is okay to have IDs that are not + // referred to. +[u4]4 +[u4]5 +[u4]8 +[u4]19 +[anchr]interface_id_array diff --git a/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd3_unexpected_invalid_associated_interface_in_array.expected b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd3_unexpected_invalid_associated_interface_in_array.expected new file mode 100644 index 0000000000..d8eda1f573 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd3_unexpected_invalid_associated_interface_in_array.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_INVALID_INTERFACE_ID diff --git a/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd3_wrong_interface_id_index_order.data b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd3_wrong_interface_id_index_order.data new file mode 100644 index 0000000000..4a63003e19 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd3_wrong_interface_id_index_order.data @@ -0,0 +1,38 @@ +[dist4]message_header // num_bytes +[u4]2 // version +[u4]0 // interface ID +[u4]3 // name +[u4]0 // flags +[u4]0 // padding +[u8]0 // request_id +[dist8]payload +[dist8]payload_interface_ids +[anchr]message_header + +[anchr]payload +[dist4]method3_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method3_params + +[anchr]param0_ptr +[dist4]associated_interface_array // num_bytes +[u4]3 // num_elements +[u4]2 // interface ID index +[u4]14 // version +[u4]3 // interface ID index +[u4]0 // version +[u4]0 // interface ID index : It is smaller than + // the first element above, which is wrong. +[u4]18 // version +[anchr]associated_interface_array + +[anchr]payload_interface_ids +[dist4]interface_id_array // num_bytes +[u4]4 // num_elements : It is okay to have IDs that are not + // referred to. +[u4]4 +[u4]5 +[u4]8 +[u4]19 +[anchr]interface_id_array diff --git a/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd3_wrong_interface_id_index_order.expected b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd3_wrong_interface_id_index_order.expected new file mode 100644 index 0000000000..420b4210e2 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/associated_conformance_mthd3_wrong_interface_id_index_order.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_ILLEGAL_INTERFACE_ID diff --git a/mojo/public/interfaces/bindings/tests/data/validation/boundscheck_msghdr_no_such_method.data b/mojo/public/interfaces/bindings/tests/data/validation/boundscheck_msghdr_no_such_method.data new file mode 100644 index 0000000000..30032a172b --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/boundscheck_msghdr_no_such_method.data @@ -0,0 +1,7 @@ +[dist4]message_header // num_bytes +[u4]0 // version number +[u4]0 // interface ID +[u4]2 // There is no Method2 +[u4]0 // flags +[u4]0 // padding +[anchr]message_header diff --git a/mojo/public/interfaces/bindings/tests/data/validation/boundscheck_msghdr_no_such_method.expected b/mojo/public/interfaces/bindings/tests/data/validation/boundscheck_msghdr_no_such_method.expected new file mode 100644 index 0000000000..a32d895c31 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/boundscheck_msghdr_no_such_method.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_MESSAGE_HEADER_UNKNOWN_METHOD diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_empty.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_empty.data new file mode 100644 index 0000000000..e69de29bb2 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_empty.data diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_empty.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_empty.expected new file mode 100644 index 0000000000..779df88cf6 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_empty.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_ILLEGAL_MEMORY_RANGE diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_incomplete_struct.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_incomplete_struct.data new file mode 100644 index 0000000000..68899f4650 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_incomplete_struct.data @@ -0,0 +1,2 @@ +[u4]24 // num_bytes: Bigger than the total size of the message. +[u4]0 // version diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_incomplete_struct.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_incomplete_struct.expected new file mode 100644 index 0000000000..779df88cf6 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_incomplete_struct.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_ILLEGAL_MEMORY_RANGE diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_incomplete_struct_header.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_incomplete_struct_header.data new file mode 100644 index 0000000000..21e7fbc02f --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_incomplete_struct_header.data @@ -0,0 +1 @@ +0x00 diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_incomplete_struct_header.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_incomplete_struct_header.expected new file mode 100644 index 0000000000..779df88cf6 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_incomplete_struct_header.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_ILLEGAL_MEMORY_RANGE diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_invalid_flag_combo.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_invalid_flag_combo.data new file mode 100644 index 0000000000..dfb2dd262d --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_invalid_flag_combo.data @@ -0,0 +1,8 @@ +[dist4]message_header // num_bytes +[u4]1 // version +[u4]0 // interface ID +[u4]0x80000000 // name +[u4]3 // flags: This combination is illegal. +[u4]0 // padding +[u8]1 // request_id +[anchr]message_header diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_invalid_flag_combo.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_invalid_flag_combo.expected new file mode 100644 index 0000000000..c33fde327b --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_invalid_flag_combo.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_MESSAGE_HEADER_INVALID_FLAGS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_missing_request_id.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_missing_request_id.data new file mode 100644 index 0000000000..27804a8390 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_missing_request_id.data @@ -0,0 +1,8 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]0x80000000 // name +[u4]1 // flags: This is a response message which expects to + // have a request ID. +[u4]0 // padding +[anchr]message_header diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_missing_request_id.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_missing_request_id.expected new file mode 100644 index 0000000000..083db1ad27 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_missing_request_id.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_MESSAGE_HEADER_MISSING_REQUEST_ID diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_no_such_method.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_no_such_method.data new file mode 100644 index 0000000000..6302baeec1 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_no_such_method.data @@ -0,0 +1,7 @@ +[dist4]message_header // num_bytes +[u4]0 // version number +[u4]0 // interface ID +[u4]9999 // There is no Method9999. +[u4]0 // flags +[u4]0 // padding +[anchr]message_header diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_no_such_method.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_no_such_method.expected new file mode 100644 index 0000000000..a32d895c31 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_no_such_method.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_MESSAGE_HEADER_UNKNOWN_METHOD diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_huge.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_huge.data new file mode 100644 index 0000000000..2fd0fcd452 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_huge.data @@ -0,0 +1,6 @@ +[u4]0xFFFFFFFF // num_bytes: Test whether a huge value will cause overflow. +[u4]0 // version +[u4]0 // interface ID +[u4]0x80000000 // name +[u4]0 // flags +[u4]0 // padding diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_huge.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_huge.expected new file mode 100644 index 0000000000..779df88cf6 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_huge.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_ILLEGAL_MEMORY_RANGE diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_less_than_min_requirement.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_less_than_min_requirement.data new file mode 100644 index 0000000000..f58eca94df --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_less_than_min_requirement.data @@ -0,0 +1,4 @@ +[dist4]message_header // num_bytes: Less than the minimal size of message + // header. +[u4]0 // version +[anchr]message_header diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_less_than_min_requirement.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_less_than_min_requirement.expected new file mode 100644 index 0000000000..25aceeea5a --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_less_than_min_requirement.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_STRUCT_HEADER diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_less_than_struct_header.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_less_than_struct_header.data new file mode 100644 index 0000000000..e98f66f147 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_less_than_struct_header.data @@ -0,0 +1,6 @@ +[u4]0 // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]0x80000000 // name +[u4]0 // flags +[u4]0 // padding diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_less_than_struct_header.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_less_than_struct_header.expected new file mode 100644 index 0000000000..25aceeea5a --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_less_than_struct_header.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_STRUCT_HEADER diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_version_mismatch_1.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_version_mismatch_1.data new file mode 100644 index 0000000000..df9e418105 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_version_mismatch_1.data @@ -0,0 +1,9 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]0x80000000 // name +[u4]0 // flags +[u4]0 // padding +[u8]0 // Extra bytes that result in mismatched |num_bytes| and + // |version|. +[anchr]message_header diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_version_mismatch_1.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_version_mismatch_1.expected new file mode 100644 index 0000000000..25aceeea5a --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_version_mismatch_1.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_STRUCT_HEADER diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_version_mismatch_2.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_version_mismatch_2.data new file mode 100644 index 0000000000..e2c574eea5 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_version_mismatch_2.data @@ -0,0 +1,10 @@ +[dist4]message_header // num_bytes +[u4]1 // version +[u4]0 // interface ID +[u4]0x80000000 // name +[u4]1 // flags +[u4]0 // padding +[u8]0 // request_id +[u8]0 // Extra bytes that result in mismatched |num_bytes| and + // |version|. +[anchr]message_header diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_version_mismatch_2.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_version_mismatch_2.expected new file mode 100644 index 0000000000..25aceeea5a --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_version_mismatch_2.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_STRUCT_HEADER diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_version_mismatch_3.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_version_mismatch_3.data new file mode 100644 index 0000000000..f7a321b6f8 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_version_mismatch_3.data @@ -0,0 +1,7 @@ +[dist4]message_header // num_bytes +[u4]8 // version: |num_bytes| is too small for |version|. +[u4]0 // interface ID +[u4]0x80000000 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_version_mismatch_3.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_version_mismatch_3.expected new file mode 100644 index 0000000000..25aceeea5a --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_msghdr_num_bytes_version_mismatch_3.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_STRUCT_HEADER diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_good.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_good.data new file mode 100644 index 0000000000..841da5e360 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_good.data @@ -0,0 +1,13 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]0 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method0_params // num_bytes +[u4]0 // version +[f]-1 // param0 +[u4]0 // padding +[anchr]method0_params diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_good.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_good.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_good.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_incomplete_struct.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_incomplete_struct.data new file mode 100644 index 0000000000..cff6a3066c --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_incomplete_struct.data @@ -0,0 +1,11 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]0 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[u4]16 // num_bytes: Incomplete struct. +[u4]0 // version +[f]-1 // param0 diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_incomplete_struct.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_incomplete_struct.expected new file mode 100644 index 0000000000..779df88cf6 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_incomplete_struct.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_ILLEGAL_MEMORY_RANGE diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_incomplete_struct_header.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_incomplete_struct_header.data new file mode 100644 index 0000000000..3f03ab2d04 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_incomplete_struct_header.data @@ -0,0 +1,9 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]0 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[u4]16 // num_bytes: Incomplete struct header. diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_incomplete_struct_header.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_incomplete_struct_header.expected new file mode 100644 index 0000000000..779df88cf6 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_incomplete_struct_header.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_ILLEGAL_MEMORY_RANGE diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_invalid_request_flags.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_invalid_request_flags.data new file mode 100644 index 0000000000..7aee806966 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_invalid_request_flags.data @@ -0,0 +1,8 @@ +[dist4]message_header // num_bytes +[u4]1 // version +[u4]0 // interface ID +[u4]0 // name +[u4]2 // flags: kMessageIsResponse is set in a request. +[u4]0 // padding +[u8]1 // request_id +[anchr]message_header diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_invalid_request_flags.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_invalid_request_flags.expected new file mode 100644 index 0000000000..c33fde327b --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_invalid_request_flags.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_MESSAGE_HEADER_INVALID_FLAGS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_invalid_request_flags2.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_invalid_request_flags2.data new file mode 100644 index 0000000000..5448c5f91b --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_invalid_request_flags2.data @@ -0,0 +1,9 @@ +[dist4]message_header // num_bytes +[u4]1 // version +[u4]0 // interface ID +[u4]0 // name +[u4]1 // flags: kMessageExpectsResponse is set in a request + // for a method that does not take a response. +[u4]0 // padding +[u8]1 // request_id +[anchr]message_header diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_invalid_request_flags2.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_invalid_request_flags2.expected new file mode 100644 index 0000000000..c33fde327b --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_invalid_request_flags2.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_MESSAGE_HEADER_INVALID_FLAGS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_struct_num_bytes_huge.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_struct_num_bytes_huge.data new file mode 100644 index 0000000000..4a3e2fea2e --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_struct_num_bytes_huge.data @@ -0,0 +1,12 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]0 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[u4]0xFFFFFFFF // num_bytes: Test whether a huge value will cause overflow. +[u4]0 // version +[f]-1 // param0 +[u4]0 // padding diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_struct_num_bytes_huge.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_struct_num_bytes_huge.expected new file mode 100644 index 0000000000..779df88cf6 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_struct_num_bytes_huge.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_ILLEGAL_MEMORY_RANGE diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_struct_num_bytes_less_than_min_requirement.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_struct_num_bytes_less_than_min_requirement.data new file mode 100644 index 0000000000..fa4c555096 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_struct_num_bytes_less_than_min_requirement.data @@ -0,0 +1,11 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]0 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method0_params // num_bytes: Less than the minimal size that we expect. +[u4]0 // version +[anchr]method0_params diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_struct_num_bytes_less_than_min_requirement.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_struct_num_bytes_less_than_min_requirement.expected new file mode 100644 index 0000000000..25aceeea5a --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_struct_num_bytes_less_than_min_requirement.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_STRUCT_HEADER diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_struct_num_bytes_less_than_struct_header.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_struct_num_bytes_less_than_struct_header.data new file mode 100644 index 0000000000..d62206ed15 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_struct_num_bytes_less_than_struct_header.data @@ -0,0 +1,12 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]0 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[u4]4 // num_bytes: Less than the size of struct header. +[u4]0 // version +[f]-1 // param0 +[u4]0 // padding diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_struct_num_bytes_less_than_struct_header.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_struct_num_bytes_less_than_struct_header.expected new file mode 100644 index 0000000000..25aceeea5a --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd0_struct_num_bytes_less_than_struct_header.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_STRUCT_HEADER diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_good.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_good.data new file mode 100644 index 0000000000..5dca2fe238 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_good.data @@ -0,0 +1,48 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]10 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method10_params // num_bytes +[u4]0 // version +[dist8]map_data_ptr // param0 +[anchr]method10_params + +[anchr]map_data_ptr +[dist4]map_data_struct_header // num_bytes +[u4]0 // version +[dist8]key_array_ptr +[dist8]value_array_ptr +[anchr]map_data_struct_header + +[anchr]key_array_ptr +[dist4]key_array_member // num_bytes +[u4]2 // num_elements +[dist8]key_string_1 +[dist8]key_string_2 +[anchr]key_array_member + +[anchr]key_string_1 +[dist4]key_string_1_member // num_bytes +[u4]5 // num_elements +0 1 2 3 4 +[anchr]key_string_1_member + +[u4]0 [u4]0 [u1]0 [u1]0 [u1]0 // manual padding for array alignment + +[anchr]key_string_2 +[dist4]key_string_2_member // num_bytes +[u4]5 // num_elements +5 6 7 8 9 +[anchr]key_string_2_member + +[u4]0 [u4]0 [u1]0 [u1]0 [u1]0 // manual padding for array alignment + +[anchr]value_array_ptr +[dist4]value_array_member // num_bytes +[u4]2 // num_elements +1 2 +[anchr]value_array_member diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_good.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_good.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_good.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_good_non_unique_keys.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_good_non_unique_keys.data new file mode 100644 index 0000000000..f64fbc388b --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_good_non_unique_keys.data @@ -0,0 +1,48 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]10 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method10_params // num_bytes +[u4]0 // version +[dist8]map_data_ptr // param0 +[anchr]method10_params + +[anchr]map_data_ptr +[dist4]map_data_struct_header // num_bytes +[u4]0 // version +[dist8]key_array_ptr +[dist8]value_array_ptr +[anchr]map_data_struct_header + +[anchr]key_array_ptr +[dist4]key_array_member // num_bytes +[u4]2 // num_elements +[dist8]key_string_1 +[dist8]key_string_2 +[anchr]key_array_member + +[anchr]key_string_1 +[dist4]key_string_1_member // num_bytes +[u4]5 // num_elements +0 1 2 3 4 +[anchr]key_string_1_member + +[u4]0 [u4]0 [u1]0 [u1]0 [u1]0 // manual padding for array alignment + +[anchr]key_string_2 +[dist4]key_string_2_member // num_bytes +[u4]5 // num_elements +0 1 2 3 4 +[anchr]key_string_2_member + +[u4]0 [u4]0 [u1]0 [u1]0 [u1]0 // manual padding for array alignment + +[anchr]value_array_ptr +[dist4]value_array_member // num_bytes +[u4]2 // num_elements +1 2 +[anchr]value_array_member diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_good_non_unique_keys.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_good_non_unique_keys.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_good_non_unique_keys.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_null_keys.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_null_keys.data new file mode 100644 index 0000000000..3a99dc2ab8 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_null_keys.data @@ -0,0 +1,25 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]10 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method10_params // num_bytes +[u4]0 // version +[dist8]map_data_ptr // param0 +[anchr]method10_params + +[anchr]map_data_ptr +[dist4]map_data_struct_header // num_bytes +[u4]0 // version +[u8]0 // null keys array +[dist8]value_array_ptr +[anchr]map_data_struct_header + +[anchr]value_array_ptr +[dist4]value_array_member // num_bytes +[u4]2 // num_elements +1 2 +[anchr]value_array_member diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_null_keys.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_null_keys.expected new file mode 100644 index 0000000000..95d8db01bb --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_null_keys.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_NULL_POINTER diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_null_values.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_null_values.data new file mode 100644 index 0000000000..459d806dac --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_null_values.data @@ -0,0 +1,40 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]10 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method10_params // num_bytes +[u4]0 // version +[dist8]map_data_ptr // param0 +[anchr]method10_params + +[anchr]map_data_ptr +[dist4]map_data_struct_header // num_bytes +[u4]0 // version +[dist8]key_array_ptr +[u8]0 // null values array +[anchr]map_data_struct_header + +[anchr]key_array_ptr +[dist4]key_array_member // num_bytes +[u4]2 // num_elements +[dist8]key_string_1 +[dist8]key_string_2 +[anchr]key_array_member + +[anchr]key_string_1 +[dist4]key_string_1_member // num_bytes +[u4]5 // num_elements +0 1 2 3 4 +[anchr]key_string_1_member + +[u4]0 [u4]0 [u1]0 [u1]0 [u1]0 // manual padding for array alignment + +[anchr]key_string_2 +[dist4]key_string_2_member // num_bytes +[u4]5 // num_elements +5 6 7 8 9 +[anchr]key_string_2_member diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_null_values.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_null_values.expected new file mode 100644 index 0000000000..95d8db01bb --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_null_values.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_NULL_POINTER diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_one_null_key.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_one_null_key.data new file mode 100644 index 0000000000..9127a26c25 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_one_null_key.data @@ -0,0 +1,40 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]10 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method10_params // num_bytes +[u4]0 // version +[dist8]map_data_ptr // param0 +[anchr]method10_params + +[anchr]map_data_ptr +[dist4]map_data_struct_header // num_bytes +[u4]0 // version +[dist8]key_array_ptr +[dist8]value_array_ptr +[anchr]map_data_struct_header + +[anchr]key_array_ptr +[dist4]key_array_member // num_bytes +[u4]2 // num_elements +[dist8]key_string_1 +[u8]0 // one null key +[anchr]key_array_member + +[anchr]key_string_1 +[dist4]key_string_1_member // num_bytes +[u4]5 // num_elements +0 1 2 3 4 +[anchr]key_string_1_member + +[u4]0 [u4]0 [u1]0 [u1]0 [u1]0 // manual padding for array alignment + +[anchr]value_array_ptr +[dist4]value_array_member // num_bytes +[u4]2 // num_elements +1 2 +[anchr]value_array_member diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_one_null_key.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_one_null_key.expected new file mode 100644 index 0000000000..95d8db01bb --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_one_null_key.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_NULL_POINTER diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_unequal_array_size.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_unequal_array_size.data new file mode 100644 index 0000000000..a2f903859f --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_unequal_array_size.data @@ -0,0 +1,48 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]10 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method10_params // num_bytes +[u4]0 // version +[dist8]map_data_ptr // param0 +[anchr]method10_params + +[anchr]map_data_ptr +[dist4]map_data_struct_header // num_bytes +[u4]0 // version +[dist8]key_array_ptr +[dist8]value_array_ptr +[anchr]map_data_struct_header + +[anchr]key_array_ptr +[dist4]key_array_member // num_bytes +[u4]2 // num_elements +[dist8]key_string_1 +[dist8]key_string_2 +[anchr]key_array_member + +[anchr]key_string_1 +[dist4]key_string_1_member // num_bytes +[u4]5 // num_elements +0 1 2 3 4 +[anchr]key_string_1_member + +[u4]0 [u4]0 [u1]0 [u1]0 [u1]0 // manual padding for array alignment + +[anchr]key_string_2 +[dist4]key_string_2_member // num_bytes +[u4]5 // num_elements +5 6 7 8 9 +[anchr]key_string_2_member + +[u4]0 [u4]0 [u1]0 [u1]0 [u1]0 // manual padding for array alignment + +[anchr]value_array_ptr +[dist4]value_array_member // num_bytes +[u4]1 // num_elements +1 // unequal size +[anchr]value_array_member diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_unequal_array_size.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_unequal_array_size.expected new file mode 100644 index 0000000000..2798d4861e --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd10_unequal_array_size.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_DIFFERENT_SIZED_ARRAYS_IN_MAP diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version0.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version0.data new file mode 100644 index 0000000000..781079bc39 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version0.data @@ -0,0 +1,19 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]11 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method11_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method11_params + +[anchr]param0_ptr +[dist4]struct_g // num_bytes +[u4]0 // version +[s4]123 // i +[u4]0 // padding +[anchr]struct_g diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version0.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version0.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version0.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version1.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version1.data new file mode 100644 index 0000000000..b9ab5bff51 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version1.data @@ -0,0 +1,20 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]11 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method11_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method11_params + +[anchr]param0_ptr +[dist4]struct_g // num_bytes +[u4]1 // version +[s4]123 // i +[u4]0 // padding +[u8]0 // struct_a +[anchr]struct_g diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version1.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version1.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version1.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version2.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version2.data new file mode 100644 index 0000000000..7d61446321 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version2.data @@ -0,0 +1,20 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]11 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method11_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method11_params + +[anchr]param0_ptr +[dist4]struct_g // num_bytes +[u4]2 // version +[s4]123 // i +[u4]0 // padding +[u8]0 // struct_a +[anchr]struct_g diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version2.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version2.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version2.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version3.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version3.data new file mode 100644 index 0000000000..3c3ee12717 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version3.data @@ -0,0 +1,28 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]11 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method11_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method11_params + +[anchr]param0_ptr +[dist4]struct_g // num_bytes +[u4]3 // version +[s4]123 // i +[b]00000001 // b +0 0 0 // padding +[u8]0 // struct_a +[dist8]str_ptr // str +[anchr]struct_g + +[anchr]str_ptr +[dist4]string // num_bytes +[u4]2 // num_elements +0 1 +[anchr]string diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version3.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version3.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version3.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version_newer_than_known_1.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version_newer_than_known_1.data new file mode 100644 index 0000000000..2e9fde6eeb --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version_newer_than_known_1.data @@ -0,0 +1,30 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]11 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method11_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method11_params + +[anchr]param0_ptr +[dist4]struct_g // num_bytes +[u4]5 // version: Newer than what the validator knows. + // It is okay that the size is the same as the latest + // version that the validator knows. +[s4]123 // i +[b]00000001 // b +0 0 0 // padding +[u8]0 // struct_a +[dist8]str_ptr // str +[anchr]struct_g + +[anchr]str_ptr +[dist4]string // num_bytes +[u4]2 // num_elements +0 1 +[anchr]string diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version_newer_than_known_1.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version_newer_than_known_1.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version_newer_than_known_1.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version_newer_than_known_2.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version_newer_than_known_2.data new file mode 100644 index 0000000000..9a956267e8 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version_newer_than_known_2.data @@ -0,0 +1,30 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]11 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method11_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method11_params + +[anchr]param0_ptr +[dist4]struct_g // num_bytes +[u4]5 // version: Newer than what the validator knows. +[s4]123 // i +[b]00000001 // b +0 0 0 // padding +[u8]0 // struct_a +[dist8]str_ptr // str +[u8]0 // unknown contents +[u8]0 // unknown contents +[anchr]struct_g + +[anchr]str_ptr +[dist4]string // num_bytes +[u4]2 // num_elements +0 1 +[anchr]string diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version_newer_than_known_2.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version_newer_than_known_2.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_good_version_newer_than_known_2.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_num_bytes_version_mismatch_1.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_num_bytes_version_mismatch_1.data new file mode 100644 index 0000000000..c2e5a8da66 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_num_bytes_version_mismatch_1.data @@ -0,0 +1,21 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]11 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method11_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method11_params + +[anchr]param0_ptr +[dist4]struct_g // num_bytes: The size is too big for the version. +[u4]1 // version +[s4]123 // i +[u4]0 // padding +[u8]0 // struct_a +[u8]0 // Unexpected contents that cause the mismatch. +[anchr]struct_g diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_num_bytes_version_mismatch_1.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_num_bytes_version_mismatch_1.expected new file mode 100644 index 0000000000..25aceeea5a --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_num_bytes_version_mismatch_1.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_STRUCT_HEADER diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_num_bytes_version_mismatch_2.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_num_bytes_version_mismatch_2.data new file mode 100644 index 0000000000..edfe5fa8b1 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_num_bytes_version_mismatch_2.data @@ -0,0 +1,19 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]11 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method11_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method11_params + +[anchr]param0_ptr +[dist4]struct_g // num_bytes: The size is too small for the version. +[u4]2 // version +[s4]123 // i +[u4]0 // padding +[anchr]struct_g diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_num_bytes_version_mismatch_2.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_num_bytes_version_mismatch_2.expected new file mode 100644 index 0000000000..25aceeea5a --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd11_num_bytes_version_mismatch_2.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_STRUCT_HEADER diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd12_invalid_request_flags.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd12_invalid_request_flags.data new file mode 100644 index 0000000000..13135aecad --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd12_invalid_request_flags.data @@ -0,0 +1,9 @@ +[dist4]message_header // num_bytes +[u4]1 // version +[u4]0 // interface ID +[u4]12 // name +[u4]0 // flags: kMessageExpectsResponse is not set but + // expected. +[u4]0 // padding +[u8]1 // request_id +[anchr]message_header diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd12_invalid_request_flags.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd12_invalid_request_flags.expected new file mode 100644 index 0000000000..c33fde327b --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd12_invalid_request_flags.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_MESSAGE_HEADER_INVALID_FLAGS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd13_good_1.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd13_good_1.data new file mode 100644 index 0000000000..51973be114 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd13_good_1.data @@ -0,0 +1,17 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]13 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method13_params // num_bytes +[u4]0 // version +[u4]0xFFFFFFFF // param0 +[u4]1234 +[u4]65535 // param1 +[u4]0xFFFFFFFF // param2 +[u4]3242 +[u4]0 // padding +[anchr]method13_params diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd13_good_1.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd13_good_1.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd13_good_1.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd13_good_2.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd13_good_2.data new file mode 100644 index 0000000000..b739731093 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd13_good_2.data @@ -0,0 +1,19 @@ +[handles]2 + +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]13 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method13_params // num_bytes +[u4]0 // version +[u4]0 // param0 +[u4]1234 +[u4]65535 // param1 +[u4]1 // param2 +[u4]3242 +[u4]0 // padding +[anchr]method13_params diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd13_good_2.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd13_good_2.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd13_good_2.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd14_good_known_enum_values.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd14_good_known_enum_values.data new file mode 100644 index 0000000000..14448497f1 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd14_good_known_enum_values.data @@ -0,0 +1,13 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]14 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method14_params // num_bytes +[u4]0 // version +[u4]0 // param0 +[u4]1 // param1 +[anchr]method14_params diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd14_good_known_enum_values.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd14_good_known_enum_values.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd14_good_known_enum_values.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd14_good_uknown_extensible_enum_value.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd14_good_uknown_extensible_enum_value.data new file mode 100644 index 0000000000..50b9ea33b0 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd14_good_uknown_extensible_enum_value.data @@ -0,0 +1,13 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]14 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method14_params // num_bytes +[u4]0 // version +[u4]0 // param0 +[u4]0xFFFFFFFF // param1: Unknown value is okay for extensible enum. +[anchr]method14_params diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd14_good_uknown_extensible_enum_value.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd14_good_uknown_extensible_enum_value.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd14_good_uknown_extensible_enum_value.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd14_uknown_non_extensible_enum_value.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd14_uknown_non_extensible_enum_value.data new file mode 100644 index 0000000000..567f23b254 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd14_uknown_non_extensible_enum_value.data @@ -0,0 +1,14 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]14 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method14_params // num_bytes +[u4]0 // version +[u4]0xFFFFFFFF // param0: Unknown value is not allowed for + // non-extensible enum. +[u4]2 // param1 +[anchr]method14_params diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd14_uknown_non_extensible_enum_value.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd14_uknown_non_extensible_enum_value.expected new file mode 100644 index 0000000000..9ef4ce3fdd --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd14_uknown_non_extensible_enum_value.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNKNOWN_ENUM_VALUE diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd15_good_empy_enum_array.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd15_good_empy_enum_array.data new file mode 100644 index 0000000000..21af8a3df1 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd15_good_empy_enum_array.data @@ -0,0 +1,22 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]15 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method15_params // num_bytes +[u4]0 // version +[dist8]enum_array_0 // param0 +[u8]0 // param1 +[anchr]method15_params + +[anchr]enum_array_0 +[dist4]enum_array_0_member // num_bytes +[u4]0 // num_elements +[anchr]enum_array_0_member + +[u8]0x5678 // This is not part of the array above (which is + // empty), so enum validation shouldn't be done on + // it. diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd15_good_empy_enum_array.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd15_good_empy_enum_array.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd15_good_empy_enum_array.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd15_good_known_enum_array_values.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd15_good_known_enum_array_values.data new file mode 100644 index 0000000000..c418d8994c --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd15_good_known_enum_array_values.data @@ -0,0 +1,27 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]15 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method15_params // num_bytes +[u4]0 // version +[dist8]enum_array_0 // param0 +[dist8]enum_array_1 // param1 +[anchr]method15_params + +[anchr]enum_array_0 +[dist4]enum_array_0_member // num_bytes +[u4]2 // num_elements +[u4]0 +[u4]1 +[anchr]enum_array_0_member + +[anchr]enum_array_1 +[dist4]enum_array_1_member // num_bytes +[u4]2 // num_elements +[u4]0 +[u4]1 +[anchr]enum_array_1_member diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd15_good_known_enum_array_values.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd15_good_known_enum_array_values.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd15_good_known_enum_array_values.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd15_good_uknown_extensible_enum_array_value.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd15_good_uknown_extensible_enum_array_value.data new file mode 100644 index 0000000000..b6be6d93c6 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd15_good_uknown_extensible_enum_array_value.data @@ -0,0 +1,20 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]15 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method15_params // num_bytes +[u4]0 // version +[u8]0 // param0 +[dist8]enum_array_1 // param1 +[anchr]method15_params + +[anchr]enum_array_1 +[dist4]enum_array_1_member // num_bytes +[u4]2 // num_elements +[u4]0 +[u4]0x1234 // Unknown value is okay for extensible enum. +[anchr]enum_array_1_member diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd15_good_uknown_extensible_enum_array_value.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd15_good_uknown_extensible_enum_array_value.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd15_good_uknown_extensible_enum_array_value.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd15_uknown_non_extensible_enum_array_value.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd15_uknown_non_extensible_enum_array_value.data new file mode 100644 index 0000000000..0a46e0a4a2 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd15_uknown_non_extensible_enum_array_value.data @@ -0,0 +1,21 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]15 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method15_params // num_bytes +[u4]0 // version +[dist8]enum_array_0 // param0 +[u8]0 // param1 +[anchr]method15_params + +[anchr]enum_array_0 +[dist4]enum_array_0_member // num_bytes +[u4]2 // num_elements +[u4]1 +[u4]0x5678 // Unknown value is not allowed for non-extensible + // enum. +[anchr]enum_array_0_member diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd15_uknown_non_extensible_enum_array_value.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd15_uknown_non_extensible_enum_array_value.expected new file mode 100644 index 0000000000..9ef4ce3fdd --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd15_uknown_non_extensible_enum_array_value.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNKNOWN_ENUM_VALUE diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd16_uknown_non_extensible_enum_map_key.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd16_uknown_non_extensible_enum_map_key.data new file mode 100644 index 0000000000..0425ea72f6 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd16_uknown_non_extensible_enum_map_key.data @@ -0,0 +1,34 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]16 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method16_params // num_bytes +[u4]0 // version +[dist8]map_data_ptr // param0 +[anchr]method16_params + +[anchr]map_data_ptr +[dist4]map_data_struct_header // num_bytes +[u4]0 // version +[dist8]key_array_ptr +[dist8]value_array_ptr +[anchr]map_data_struct_header + +[anchr]key_array_ptr +[dist4]key_array_member // num_bytes +[u4]2 // num_elements +[u4]0x5678 // Unknown value is not allowed for non-extensible + // enum. +[u4]1 +[anchr]key_array_member + +[anchr]value_array_ptr +[dist4]value_array_member // num_bytes +[u4]2 // num_elements +[u4]1 +[u4]2 +[anchr]value_array_member diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd16_uknown_non_extensible_enum_map_key.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd16_uknown_non_extensible_enum_map_key.expected new file mode 100644 index 0000000000..9ef4ce3fdd --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd16_uknown_non_extensible_enum_map_key.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNKNOWN_ENUM_VALUE diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd16_uknown_non_extensible_enum_map_value.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd16_uknown_non_extensible_enum_map_value.data new file mode 100644 index 0000000000..2c2ea26d93 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd16_uknown_non_extensible_enum_map_value.data @@ -0,0 +1,34 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]16 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method16_params // num_bytes +[u4]0 // version +[dist8]map_data_ptr // param0 +[anchr]method16_params + +[anchr]map_data_ptr +[dist4]map_data_struct_header // num_bytes +[u4]0 // version +[dist8]key_array_ptr +[dist8]value_array_ptr +[anchr]map_data_struct_header + +[anchr]key_array_ptr +[dist4]key_array_member // num_bytes +[u4]2 // num_elements +[u4]1 +[u4]2 +[anchr]key_array_member + +[anchr]value_array_ptr +[dist4]value_array_member // num_bytes +[u4]2 // num_elements +[u4]0x5678 // Unknown value is not allowed for non-extensible + // enum. +[u4]1 +[anchr]value_array_member diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd16_uknown_non_extensible_enum_map_value.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd16_uknown_non_extensible_enum_map_value.expected new file mode 100644 index 0000000000..9ef4ce3fdd --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd16_uknown_non_extensible_enum_map_value.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNKNOWN_ENUM_VALUE diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd17_good.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd17_good.data new file mode 100644 index 0000000000..48807ab36f --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd17_good.data @@ -0,0 +1,23 @@ +[handles]10 // Larger than the number of handles that we know about is okay. + +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]17 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method17_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method17_params + +[anchr]param0_ptr +[dist4]interface_array // num_bytes +[u4]2 // num_elements +[u4]4 // handle +[u4]14 // version +[u4]5 // handle +[u4]18 // version +[anchr]interface_array diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd17_good.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd17_good.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd17_good.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd17_interface_handle_out_of_range_in_array.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd17_interface_handle_out_of_range_in_array.data new file mode 100644 index 0000000000..e549a10e3a --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd17_interface_handle_out_of_range_in_array.data @@ -0,0 +1,24 @@ +[handles]10 + +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]17 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method17_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method17_params + +[anchr]param0_ptr +[dist4]interface_array // num_bytes +[u4]2 // num_elements +[u4]4 // handle +[u4]14 // version +[u4]10 // handle: It is outside of the valid encoded handle + // range [0, 10) +[u4]18 // version +[anchr]interface_array diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd17_interface_handle_out_of_range_in_array.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd17_interface_handle_out_of_range_in_array.expected new file mode 100644 index 0000000000..eef8e38a84 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd17_interface_handle_out_of_range_in_array.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_ILLEGAL_HANDLE diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd17_unexpected_invalid_interface_in_array.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd17_unexpected_invalid_interface_in_array.data new file mode 100644 index 0000000000..1ce1d92fe5 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd17_unexpected_invalid_interface_in_array.data @@ -0,0 +1,23 @@ +[handles]10 + +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]17 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method17_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method17_params + +[anchr]param0_ptr +[dist4]interface_array // num_bytes +[u4]2 // num_elements +[u4]4 // handle +[u4]14 // version +[u4]0xFFFFFFFF // handle: An unexpected invalid handle. +[u4]18 // version +[anchr]interface_array diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd17_unexpected_invalid_interface_in_array.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd17_unexpected_invalid_interface_in_array.expected new file mode 100644 index 0000000000..6768236f6e --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd17_unexpected_invalid_interface_in_array.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_INVALID_HANDLE diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd18_good.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd18_good.data new file mode 100644 index 0000000000..663796d50e --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd18_good.data @@ -0,0 +1,14 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]18 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method18_params // num_bytes +[u4]0 // version +[u4]0 // param0: Size 0 indicating the inlined union is null. +[u4]0 // param0: Tag field ignored. +[u8]0 // param0: Payload field ignored. +[anchr]method18_params diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd18_good.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd18_good.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd18_good.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd19_exceed_recursion_limit.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd19_exceed_recursion_limit.data new file mode 100644 index 0000000000..96e52d5ee2 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd19_exceed_recursion_limit.data @@ -0,0 +1,612 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]19 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method0_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method0_params + +[anchr]param0_ptr +[dist4]struct_a1 // num_bytes +[u4]0 // version +[dist8]struct_a2_ptr // struct_a2 +[anchr]struct_a1 + +[anchr]struct_a2_ptr +[dist4]struct_a2 // num_bytes +[u4]0 // version +[dist8]struct_a3_ptr // struct_a2 +[anchr]struct_a2 + +[anchr]struct_a3_ptr +[dist4]struct_a3 // num_bytes +[u4]0 // version +[dist8]struct_a4_ptr // struct_a3 +[anchr]struct_a3 + +[anchr]struct_a4_ptr +[dist4]struct_a4 // num_bytes +[u4]0 // version +[dist8]struct_a5_ptr // struct_a4 +[anchr]struct_a4 + +[anchr]struct_a5_ptr +[dist4]struct_a5 // num_bytes +[u4]0 // version +[dist8]struct_a6_ptr // struct_a5 +[anchr]struct_a5 + +[anchr]struct_a6_ptr +[dist4]struct_a6 // num_bytes +[u4]0 // version +[dist8]struct_a7_ptr // struct_a6 +[anchr]struct_a6 + +[anchr]struct_a7_ptr +[dist4]struct_a7 // num_bytes +[u4]0 // version +[dist8]struct_a8_ptr // struct_a7 +[anchr]struct_a7 + +[anchr]struct_a8_ptr +[dist4]struct_a8 // num_bytes +[u4]0 // version +[dist8]struct_a9_ptr // struct_a8 +[anchr]struct_a8 + +[anchr]struct_a9_ptr +[dist4]struct_a9 // num_bytes +[u4]0 // version +[dist8]struct_a10_ptr // struct_a9 +[anchr]struct_a9 + +[anchr]struct_a10_ptr +[dist4]struct_a10 // num_bytes +[u4]0 // version +[dist8]struct_a11_ptr // struct_a10 +[anchr]struct_a10 + +[anchr]struct_a11_ptr +[dist4]struct_a11 // num_bytes +[u4]0 // version +[dist8]struct_a12_ptr // struct_a11 +[anchr]struct_a11 + +[anchr]struct_a12_ptr +[dist4]struct_a12 // num_bytes +[u4]0 // version +[dist8]struct_a13_ptr // struct_a12 +[anchr]struct_a12 + +[anchr]struct_a13_ptr +[dist4]struct_a13 // num_bytes +[u4]0 // version +[dist8]struct_a14_ptr // struct_a13 +[anchr]struct_a13 + +[anchr]struct_a14_ptr +[dist4]struct_a14 // num_bytes +[u4]0 // version +[dist8]struct_a15_ptr // struct_a14 +[anchr]struct_a14 + +[anchr]struct_a15_ptr +[dist4]struct_a15 // num_bytes +[u4]0 // version +[dist8]struct_a16_ptr // struct_a15 +[anchr]struct_a15 + +[anchr]struct_a16_ptr +[dist4]struct_a16 // num_bytes +[u4]0 // version +[dist8]struct_a17_ptr // struct_a16 +[anchr]struct_a16 + +[anchr]struct_a17_ptr +[dist4]struct_a17 // num_bytes +[u4]0 // version +[dist8]struct_a18_ptr // struct_a17 +[anchr]struct_a17 + +[anchr]struct_a18_ptr +[dist4]struct_a18 // num_bytes +[u4]0 // version +[dist8]struct_a19_ptr // struct_a18 +[anchr]struct_a18 + +[anchr]struct_a19_ptr +[dist4]struct_a19 // num_bytes +[u4]0 // version +[dist8]struct_a20_ptr // struct_a19 +[anchr]struct_a19 + +[anchr]struct_a20_ptr +[dist4]struct_a20 // num_bytes +[u4]0 // version +[dist8]struct_a21_ptr // struct_a20 +[anchr]struct_a20 + +[anchr]struct_a21_ptr +[dist4]struct_a21 // num_bytes +[u4]0 // version +[dist8]struct_a22_ptr // struct_a21 +[anchr]struct_a21 + +[anchr]struct_a22_ptr +[dist4]struct_a22 // num_bytes +[u4]0 // version +[dist8]struct_a23_ptr // struct_a22 +[anchr]struct_a22 + +[anchr]struct_a23_ptr +[dist4]struct_a23 // num_bytes +[u4]0 // version +[dist8]struct_a24_ptr // struct_a23 +[anchr]struct_a23 + +[anchr]struct_a24_ptr +[dist4]struct_a24 // num_bytes +[u4]0 // version +[dist8]struct_a25_ptr // struct_a24 +[anchr]struct_a24 + +[anchr]struct_a25_ptr +[dist4]struct_a25 // num_bytes +[u4]0 // version +[dist8]struct_a26_ptr // struct_a25 +[anchr]struct_a25 + +[anchr]struct_a26_ptr +[dist4]struct_a26 // num_bytes +[u4]0 // version +[dist8]struct_a27_ptr // struct_a26 +[anchr]struct_a26 + +[anchr]struct_a27_ptr +[dist4]struct_a27 // num_bytes +[u4]0 // version +[dist8]struct_a28_ptr // struct_a27 +[anchr]struct_a27 + +[anchr]struct_a28_ptr +[dist4]struct_a28 // num_bytes +[u4]0 // version +[dist8]struct_a29_ptr // struct_a28 +[anchr]struct_a28 + +[anchr]struct_a29_ptr +[dist4]struct_a29 // num_bytes +[u4]0 // version +[dist8]struct_a30_ptr // struct_a29 +[anchr]struct_a29 + +[anchr]struct_a30_ptr +[dist4]struct_a30 // num_bytes +[u4]0 // version +[dist8]struct_a31_ptr // struct_a30 +[anchr]struct_a30 + +[anchr]struct_a31_ptr +[dist4]struct_a31 // num_bytes +[u4]0 // version +[dist8]struct_a32_ptr // struct_a31 +[anchr]struct_a31 + +[anchr]struct_a32_ptr +[dist4]struct_a32 // num_bytes +[u4]0 // version +[dist8]struct_a33_ptr // struct_a32 +[anchr]struct_a32 + +[anchr]struct_a33_ptr +[dist4]struct_a33 // num_bytes +[u4]0 // version +[dist8]struct_a34_ptr // struct_a33 +[anchr]struct_a33 + +[anchr]struct_a34_ptr +[dist4]struct_a34 // num_bytes +[u4]0 // version +[dist8]struct_a35_ptr // struct_a34 +[anchr]struct_a34 + +[anchr]struct_a35_ptr +[dist4]struct_a35 // num_bytes +[u4]0 // version +[dist8]struct_a36_ptr // struct_a35 +[anchr]struct_a35 + +[anchr]struct_a36_ptr +[dist4]struct_a36 // num_bytes +[u4]0 // version +[dist8]struct_a37_ptr // struct_a36 +[anchr]struct_a36 + +[anchr]struct_a37_ptr +[dist4]struct_a37 // num_bytes +[u4]0 // version +[dist8]struct_a38_ptr // struct_a37 +[anchr]struct_a37 + +[anchr]struct_a38_ptr +[dist4]struct_a38 // num_bytes +[u4]0 // version +[dist8]struct_a39_ptr // struct_a38 +[anchr]struct_a38 + +[anchr]struct_a39_ptr +[dist4]struct_a39 // num_bytes +[u4]0 // version +[dist8]struct_a40_ptr // struct_a39 +[anchr]struct_a39 + +[anchr]struct_a40_ptr +[dist4]struct_a40 // num_bytes +[u4]0 // version +[dist8]struct_a41_ptr // struct_a40 +[anchr]struct_a40 + +[anchr]struct_a41_ptr +[dist4]struct_a41 // num_bytes +[u4]0 // version +[dist8]struct_a42_ptr // struct_a41 +[anchr]struct_a41 + +[anchr]struct_a42_ptr +[dist4]struct_a42 // num_bytes +[u4]0 // version +[dist8]struct_a43_ptr // struct_a42 +[anchr]struct_a42 + +[anchr]struct_a43_ptr +[dist4]struct_a43 // num_bytes +[u4]0 // version +[dist8]struct_a44_ptr // struct_a43 +[anchr]struct_a43 + +[anchr]struct_a44_ptr +[dist4]struct_a44 // num_bytes +[u4]0 // version +[dist8]struct_a45_ptr // struct_a44 +[anchr]struct_a44 + +[anchr]struct_a45_ptr +[dist4]struct_a45 // num_bytes +[u4]0 // version +[dist8]struct_a46_ptr // struct_a45 +[anchr]struct_a45 + +[anchr]struct_a46_ptr +[dist4]struct_a46 // num_bytes +[u4]0 // version +[dist8]struct_a47_ptr // struct_a46 +[anchr]struct_a46 + +[anchr]struct_a47_ptr +[dist4]struct_a47 // num_bytes +[u4]0 // version +[dist8]struct_a48_ptr // struct_a47 +[anchr]struct_a47 + +[anchr]struct_a48_ptr +[dist4]struct_a48 // num_bytes +[u4]0 // version +[dist8]struct_a49_ptr // struct_a48 +[anchr]struct_a48 + +[anchr]struct_a49_ptr +[dist4]struct_a49 // num_bytes +[u4]0 // version +[dist8]struct_a50_ptr // struct_a49 +[anchr]struct_a49 + +[anchr]struct_a50_ptr +[dist4]struct_a50 // num_bytes +[u4]0 // version +[dist8]struct_a51_ptr // struct_a50 +[anchr]struct_a50 + +[anchr]struct_a51_ptr +[dist4]struct_a51 // num_bytes +[u4]0 // version +[dist8]struct_a52_ptr // struct_a51 +[anchr]struct_a51 + +[anchr]struct_a52_ptr +[dist4]struct_a52 // num_bytes +[u4]0 // version +[dist8]struct_a53_ptr // struct_a52 +[anchr]struct_a52 + +[anchr]struct_a53_ptr +[dist4]struct_a53 // num_bytes +[u4]0 // version +[dist8]struct_a54_ptr // struct_a53 +[anchr]struct_a53 + +[anchr]struct_a54_ptr +[dist4]struct_a54 // num_bytes +[u4]0 // version +[dist8]struct_a55_ptr // struct_a54 +[anchr]struct_a54 + +[anchr]struct_a55_ptr +[dist4]struct_a55 // num_bytes +[u4]0 // version +[dist8]struct_a56_ptr // struct_a55 +[anchr]struct_a55 + +[anchr]struct_a56_ptr +[dist4]struct_a56 // num_bytes +[u4]0 // version +[dist8]struct_a57_ptr // struct_a56 +[anchr]struct_a56 + +[anchr]struct_a57_ptr +[dist4]struct_a57 // num_bytes +[u4]0 // version +[dist8]struct_a58_ptr // struct_a57 +[anchr]struct_a57 + +[anchr]struct_a58_ptr +[dist4]struct_a58 // num_bytes +[u4]0 // version +[dist8]struct_a59_ptr // struct_a58 +[anchr]struct_a58 + +[anchr]struct_a59_ptr +[dist4]struct_a59 // num_bytes +[u4]0 // version +[dist8]struct_a60_ptr // struct_a59 +[anchr]struct_a59 + +[anchr]struct_a60_ptr +[dist4]struct_a60 // num_bytes +[u4]0 // version +[dist8]struct_a61_ptr // struct_a60 +[anchr]struct_a60 + +[anchr]struct_a61_ptr +[dist4]struct_a61 // num_bytes +[u4]0 // version +[dist8]struct_a62_ptr // struct_a61 +[anchr]struct_a61 + +[anchr]struct_a62_ptr +[dist4]struct_a62 // num_bytes +[u4]0 // version +[dist8]struct_a63_ptr // struct_a62 +[anchr]struct_a62 + +[anchr]struct_a63_ptr +[dist4]struct_a63 // num_bytes +[u4]0 // version +[dist8]struct_a64_ptr // struct_a63 +[anchr]struct_a63 + +[anchr]struct_a64_ptr +[dist4]struct_a64 // num_bytes +[u4]0 // version +[dist8]struct_a65_ptr // struct_a64 +[anchr]struct_a64 + +[anchr]struct_a65_ptr +[dist4]struct_a65 // num_bytes +[u4]0 // version +[dist8]struct_a66_ptr // struct_a65 +[anchr]struct_a65 + +[anchr]struct_a66_ptr +[dist4]struct_a66 // num_bytes +[u4]0 // version +[dist8]struct_a67_ptr // struct_a66 +[anchr]struct_a66 + +[anchr]struct_a67_ptr +[dist4]struct_a67 // num_bytes +[u4]0 // version +[dist8]struct_a68_ptr // struct_a67 +[anchr]struct_a67 + +[anchr]struct_a68_ptr +[dist4]struct_a68 // num_bytes +[u4]0 // version +[dist8]struct_a69_ptr // struct_a68 +[anchr]struct_a68 + +[anchr]struct_a69_ptr +[dist4]struct_a69 // num_bytes +[u4]0 // version +[dist8]struct_a70_ptr // struct_a69 +[anchr]struct_a69 + +[anchr]struct_a70_ptr +[dist4]struct_a70 // num_bytes +[u4]0 // version +[dist8]struct_a71_ptr // struct_a70 +[anchr]struct_a70 + +[anchr]struct_a71_ptr +[dist4]struct_a71 // num_bytes +[u4]0 // version +[dist8]struct_a72_ptr // struct_a71 +[anchr]struct_a71 + +[anchr]struct_a72_ptr +[dist4]struct_a72 // num_bytes +[u4]0 // version +[dist8]struct_a73_ptr // struct_a72 +[anchr]struct_a72 + +[anchr]struct_a73_ptr +[dist4]struct_a73 // num_bytes +[u4]0 // version +[dist8]struct_a74_ptr // struct_a73 +[anchr]struct_a73 + +[anchr]struct_a74_ptr +[dist4]struct_a74 // num_bytes +[u4]0 // version +[dist8]struct_a75_ptr // struct_a74 +[anchr]struct_a74 + +[anchr]struct_a75_ptr +[dist4]struct_a75 // num_bytes +[u4]0 // version +[dist8]struct_a76_ptr // struct_a75 +[anchr]struct_a75 + +[anchr]struct_a76_ptr +[dist4]struct_a76 // num_bytes +[u4]0 // version +[dist8]struct_a77_ptr // struct_a76 +[anchr]struct_a76 + +[anchr]struct_a77_ptr +[dist4]struct_a77 // num_bytes +[u4]0 // version +[dist8]struct_a78_ptr // struct_a77 +[anchr]struct_a77 + +[anchr]struct_a78_ptr +[dist4]struct_a78 // num_bytes +[u4]0 // version +[dist8]struct_a79_ptr // struct_a78 +[anchr]struct_a78 + +[anchr]struct_a79_ptr +[dist4]struct_a79 // num_bytes +[u4]0 // version +[dist8]struct_a80_ptr // struct_a79 +[anchr]struct_a79 + +[anchr]struct_a80_ptr +[dist4]struct_a80 // num_bytes +[u4]0 // version +[dist8]struct_a81_ptr // struct_a80 +[anchr]struct_a80 + +[anchr]struct_a81_ptr +[dist4]struct_a81 // num_bytes +[u4]0 // version +[dist8]struct_a82_ptr // struct_a81 +[anchr]struct_a81 + +[anchr]struct_a82_ptr +[dist4]struct_a82 // num_bytes +[u4]0 // version +[dist8]struct_a83_ptr // struct_a82 +[anchr]struct_a82 + +[anchr]struct_a83_ptr +[dist4]struct_a83 // num_bytes +[u4]0 // version +[dist8]struct_a84_ptr // struct_a83 +[anchr]struct_a83 + +[anchr]struct_a84_ptr +[dist4]struct_a84 // num_bytes +[u4]0 // version +[dist8]struct_a85_ptr // struct_a84 +[anchr]struct_a84 + +[anchr]struct_a85_ptr +[dist4]struct_a85 // num_bytes +[u4]0 // version +[dist8]struct_a86_ptr // struct_a85 +[anchr]struct_a85 + +[anchr]struct_a86_ptr +[dist4]struct_a86 // num_bytes +[u4]0 // version +[dist8]struct_a87_ptr // struct_a86 +[anchr]struct_a86 + +[anchr]struct_a87_ptr +[dist4]struct_a87 // num_bytes +[u4]0 // version +[dist8]struct_a88_ptr // struct_a87 +[anchr]struct_a87 + +[anchr]struct_a88_ptr +[dist4]struct_a88 // num_bytes +[u4]0 // version +[dist8]struct_a89_ptr // struct_a88 +[anchr]struct_a88 + +[anchr]struct_a89_ptr +[dist4]struct_a89 // num_bytes +[u4]0 // version +[dist8]struct_a90_ptr // struct_a89 +[anchr]struct_a89 + +[anchr]struct_a90_ptr +[dist4]struct_a90 // num_bytes +[u4]0 // version +[dist8]struct_a91_ptr // struct_a90 +[anchr]struct_a90 + +[anchr]struct_a91_ptr +[dist4]struct_a91 // num_bytes +[u4]0 // version +[dist8]struct_a92_ptr // struct_a91 +[anchr]struct_a91 + +[anchr]struct_a92_ptr +[dist4]struct_a92 // num_bytes +[u4]0 // version +[dist8]struct_a93_ptr // struct_a92 +[anchr]struct_a92 + +[anchr]struct_a93_ptr +[dist4]struct_a93 // num_bytes +[u4]0 // version +[dist8]struct_a94_ptr // struct_a93 +[anchr]struct_a93 + +[anchr]struct_a94_ptr +[dist4]struct_a94 // num_bytes +[u4]0 // version +[dist8]struct_a95_ptr // struct_a94 +[anchr]struct_a94 + +[anchr]struct_a95_ptr +[dist4]struct_a95 // num_bytes +[u4]0 // version +[dist8]struct_a96_ptr // struct_a95 +[anchr]struct_a95 + +[anchr]struct_a96_ptr +[dist4]struct_a96 // num_bytes +[u4]0 // version +[dist8]struct_a97_ptr // struct_a96 +[anchr]struct_a96 + +[anchr]struct_a97_ptr +[dist4]struct_a97 // num_bytes +[u4]0 // version +[dist8]struct_a98_ptr // struct_a97 +[anchr]struct_a97 + +[anchr]struct_a98_ptr +[dist4]struct_a98 // num_bytes +[u4]0 // version +[dist8]struct_a99_ptr // struct_a98 +[anchr]struct_a98 + +[anchr]struct_a99_ptr +[dist4]struct_a99 // num_bytes +[u4]0 // version +[dist8]struct_a100_ptr // struct_a99 +[anchr]struct_a99 + +[anchr]struct_a100_ptr +[dist4]struct_a100 // num_bytes +[u4]0 // version +[u8]0 // struct_a100 +[anchr]struct_a100 diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd19_exceed_recursion_limit.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd19_exceed_recursion_limit.expected new file mode 100644 index 0000000000..81d6cd84e4 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd19_exceed_recursion_limit.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_MAX_RECURSION_DEPTH
\ No newline at end of file diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd1_good.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd1_good.data new file mode 100644 index 0000000000..b6c201a948 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd1_good.data @@ -0,0 +1,18 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]1 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method1_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method1_params + +[anchr]param0_ptr +[dist4]struct_a // num_bytes +[u4]0 // version +[u8]1234 // i +[anchr]struct_a diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd1_good.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd1_good.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd1_good.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd1_misaligned_struct.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd1_misaligned_struct.data new file mode 100644 index 0000000000..ec39b71d03 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd1_misaligned_struct.data @@ -0,0 +1,20 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]1 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method1_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method1_params + +[u1]0 // Causes the following struct to be misaligned. + +[anchr]param0_ptr +[dist4]struct_a // num_bytes +[u4]0 // version +[u8]1234 // i +[anchr]struct_a diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd1_misaligned_struct.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd1_misaligned_struct.expected new file mode 100644 index 0000000000..acca999b3f --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd1_misaligned_struct.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_MISALIGNED_OBJECT diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd1_struct_pointer_overflow.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd1_struct_pointer_overflow.data new file mode 100644 index 0000000000..6d9205093b --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd1_struct_pointer_overflow.data @@ -0,0 +1,13 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]1 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method1_params // num_bytes +[u4]0 // version +[u8]0xFFFFFFFFFFFFFFFF // param0: Test whether decoding the pointer causes + // overflow. +[anchr]method1_params diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd1_struct_pointer_overflow.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd1_struct_pointer_overflow.expected new file mode 100644 index 0000000000..23abb8cbb7 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd1_struct_pointer_overflow.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_ILLEGAL_POINTER diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd1_unexpected_null_struct.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd1_unexpected_null_struct.data new file mode 100644 index 0000000000..569733bcb3 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd1_unexpected_null_struct.data @@ -0,0 +1,12 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]1 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method1_params // num_bytes +[u4]0 // version +[u8]0 // param0: An unexpected null pointer. +[anchr]method1_params diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd1_unexpected_null_struct.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd1_unexpected_null_struct.expected new file mode 100644 index 0000000000..95d8db01bb --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd1_unexpected_null_struct.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_NULL_POINTER diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd20_good.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd20_good.data new file mode 100644 index 0000000000..8ec608bcd1 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd20_good.data @@ -0,0 +1,57 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]20 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method20_params // num_bytes +[u4]0 // version +[dist8]map_data_ptr // param0 +[anchr]method20_params + +[anchr]map_data_ptr +[dist4]map_data_struct_header // num_bytes +[u4]0 // version +[dist8]key_array_ptr +[dist8]value_array_ptr +[anchr]map_data_struct_header + +[anchr]key_array_ptr +[dist4]key_array_member // num_bytes +[u4]2 // num_elements +[dist8]key_struct_b_1 +[dist8]key_struct_b_2 +[anchr]key_array_member + +[anchr]key_struct_b_1 +[dist4]key_struct_b_1_member // num_bytes +[u4]0 // version +[dist8]key_struct_a_1 // struct_a +[anchr]key_struct_b_1_member + +[anchr]key_struct_a_1 +[dist4]key_struct_a_1_member // num_bytes +[u4]0 // version +[u8]1234 // i +[anchr]key_struct_a_1_member + +[anchr]key_struct_b_2 +[dist4]key_struct_b_2_member // num_bytes +[u4]0 // version +[dist8]key_struct_a_2 // struct_a +[anchr]key_struct_b_2_member + +[anchr]key_struct_a_2 +[dist4]key_struct_a_2_member // num_bytes +[u4]0 // version +[u8]5678 // i +[anchr]key_struct_a_2_member + +[anchr]value_array_ptr +[dist4]value_array_member // num_bytes +[u4]2 // num_elements +[u1]1 +[u1]2 +[anchr]value_array_member diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd20_good.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd20_good.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd20_good.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd21_empty_extensible_enum_accepts_any_value.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd21_empty_extensible_enum_accepts_any_value.data new file mode 100644 index 0000000000..d3ae88e3e6 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd21_empty_extensible_enum_accepts_any_value.data @@ -0,0 +1,13 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]21 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method21_params // num_bytes +[u4]0 // version +[u4]7 // param0. All values are valid for an extensible enum. +[u4]0 // padding +[anchr]method21_params diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd21_empty_extensible_enum_accepts_any_value.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd21_empty_extensible_enum_accepts_any_value.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd21_empty_extensible_enum_accepts_any_value.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd22_empty_nonextensible_enum_accepts_no_values.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd22_empty_nonextensible_enum_accepts_no_values.data new file mode 100644 index 0000000000..414785ceb1 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd22_empty_nonextensible_enum_accepts_no_values.data @@ -0,0 +1,14 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]22 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method21_params // num_bytes +[u4]0 // version +[u4]0 // param0. No values are valid for an empty + // non-extensible enum. +[u4]0 // padding +[anchr]method21_params diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd22_empty_nonextensible_enum_accepts_no_values.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd22_empty_nonextensible_enum_accepts_no_values.expected new file mode 100644 index 0000000000..9ef4ce3fdd --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd22_empty_nonextensible_enum_accepts_no_values.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNKNOWN_ENUM_VALUE diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd2_good.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd2_good.data new file mode 100644 index 0000000000..40719f5708 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd2_good.data @@ -0,0 +1,34 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]2 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method2_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[dist8]param1_ptr // param1 +[anchr]method2_params + +[anchr]param0_ptr +[dist4]struct_b // num_bytes +[u4]0 // version +[dist8]struct_a_ptr // struct_a +[anchr]struct_b + +[u8]0 // Having extra bytes in the middle is okay if the following objects are + // still properly alignmented. + +[anchr]struct_a_ptr +[dist4]struct_a_member // num_bytes +[u4]0 // version +[u8]12345 // i +[anchr]struct_a_member + +[anchr]param1_ptr +[dist4]struct_a_param // num_bytes +[u4]0 // version +[u8]67890 // i +[anchr]struct_a_param diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd2_good.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd2_good.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd2_good.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd2_multiple_pointers_to_same_struct.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd2_multiple_pointers_to_same_struct.data new file mode 100644 index 0000000000..ef6525b008 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd2_multiple_pointers_to_same_struct.data @@ -0,0 +1,27 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]2 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method2_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[dist8]param1_ptr // param1 +[anchr]method2_params + +[anchr]param0_ptr +[dist4]struct_b // num_bytes +[u4]0 // version +[dist8]struct_a_ptr // struct_a +[anchr]struct_b + +// There are two pointers pointing to the same struct. +[anchr]struct_a_ptr +[anchr]param1_ptr +[dist4]struct_a // num_bytes +[u4]0 // version +[u8]12345 // i +[anchr]struct_a diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd2_multiple_pointers_to_same_struct.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd2_multiple_pointers_to_same_struct.expected new file mode 100644 index 0000000000..779df88cf6 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd2_multiple_pointers_to_same_struct.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_ILLEGAL_MEMORY_RANGE diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd2_overlapped_objects.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd2_overlapped_objects.data new file mode 100644 index 0000000000..58b25a1aa9 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd2_overlapped_objects.data @@ -0,0 +1,32 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]2 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method2_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[dist8]param1_ptr // param1 +[anchr]method2_params + +[anchr]param0_ptr +[dist4]struct_b // num_bytes +[u4]0 // version +[dist8]struct_a_ptr // struct_a +[anchr]struct_b + +[anchr]struct_a_ptr +[dist4]struct_a_member // num_bytes +[u4]0 // version + +[anchr]param1_ptr +// The following |num_bytes| and |version| fields are also the |i| field of the +// previous struct. +[dist4]struct_a_param // num_bytes +[u4]0 // version +[anchr]struct_a_member +[u8]67890 // i +[anchr]struct_a_param diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd2_overlapped_objects.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd2_overlapped_objects.expected new file mode 100644 index 0000000000..779df88cf6 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd2_overlapped_objects.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_ILLEGAL_MEMORY_RANGE diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd2_wrong_layout_order.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd2_wrong_layout_order.data new file mode 100644 index 0000000000..3038ed8097 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd2_wrong_layout_order.data @@ -0,0 +1,34 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]2 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method2_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[dist8]param1_ptr // param1 +[anchr]method2_params + +[anchr]param0_ptr +[dist4]struct_b // num_bytes +[u4]0 // version +[dist8]struct_a_ptr // struct_a +[anchr]struct_b + +// The following two structs are arranged in wrong order. + +[anchr]param1_ptr +[dist4]struct_a_param // num_bytes +[u4]0 // version +[u8]67890 // i +[anchr]struct_a_param + +[anchr]struct_a_ptr +[dist4]struct_a_member // num_bytes +[u4]0 // version +[u8]12345 // i +[anchr]struct_a_member + diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd2_wrong_layout_order.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd2_wrong_layout_order.expected new file mode 100644 index 0000000000..779df88cf6 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd2_wrong_layout_order.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_ILLEGAL_MEMORY_RANGE diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_array_num_bytes_huge.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_array_num_bytes_huge.data new file mode 100644 index 0000000000..681463663f --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_array_num_bytes_huge.data @@ -0,0 +1,18 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]3 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method3_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method3_params + +[anchr]param0_ptr +[u4]0xFFFFFFFF // num_bytes: Test whether a huge value will cause overflow. +[u4]12 // num_elements +[b]01010101 +[b]00001111 diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_array_num_bytes_huge.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_array_num_bytes_huge.expected new file mode 100644 index 0000000000..779df88cf6 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_array_num_bytes_huge.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_ILLEGAL_MEMORY_RANGE diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_array_num_bytes_less_than_array_header.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_array_num_bytes_less_than_array_header.data new file mode 100644 index 0000000000..45021c0634 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_array_num_bytes_less_than_array_header.data @@ -0,0 +1,18 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]3 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method3_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method3_params + +[anchr]param0_ptr +[u4]7 // num_bytes: Less than the size of array header. +[u4]12 // num_elements +[b]01010101 +[b]00001111 diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_array_num_bytes_less_than_array_header.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_array_num_bytes_less_than_array_header.expected new file mode 100644 index 0000000000..5a1ec4ef20 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_array_num_bytes_less_than_array_header.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_ARRAY_HEADER diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_array_num_bytes_less_than_necessary_size.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_array_num_bytes_less_than_necessary_size.data new file mode 100644 index 0000000000..3d3870298f --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_array_num_bytes_less_than_necessary_size.data @@ -0,0 +1,20 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]3 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method3_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method3_params + +[anchr]param0_ptr +[dist4]array // num_bytes: Less than the size needed (array header + 12 boolean + // values). +[u4]12 // num_elements +[b]01010101 +[anchr]array +[b]00001111 diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_array_num_bytes_less_than_necessary_size.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_array_num_bytes_less_than_necessary_size.expected new file mode 100644 index 0000000000..5a1ec4ef20 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_array_num_bytes_less_than_necessary_size.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_ARRAY_HEADER diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_array_pointer_overflow.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_array_pointer_overflow.data new file mode 100644 index 0000000000..2f9e091b04 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_array_pointer_overflow.data @@ -0,0 +1,13 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]3 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method3_params // num_bytes +[u4]0 // version +[u8]0xFFFFFFFFFFFFFFFF // param0: Test whether decoding the pointer causes + // overflow. +[anchr]method3_params diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_array_pointer_overflow.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_array_pointer_overflow.expected new file mode 100644 index 0000000000..23abb8cbb7 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_array_pointer_overflow.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_ILLEGAL_POINTER diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_good.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_good.data new file mode 100644 index 0000000000..ad26763f5f --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_good.data @@ -0,0 +1,19 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]3 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method3_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method3_params + +[anchr]param0_ptr +[dist4]array // num_bytes +[u4]12 // num_elements +[b]01010101 +[b]00001111 +[anchr]array diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_good.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_good.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_good.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_incomplete_array.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_incomplete_array.data new file mode 100644 index 0000000000..d7734589ce --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_incomplete_array.data @@ -0,0 +1,16 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]3 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method3_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method3_params + +[anchr]param0_ptr +[u4]16 // num_bytes +[u1]0 // num_elements: Incomplete array. diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_incomplete_array.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_incomplete_array.expected new file mode 100644 index 0000000000..779df88cf6 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_incomplete_array.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_ILLEGAL_MEMORY_RANGE diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_incomplete_array_header.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_incomplete_array_header.data new file mode 100644 index 0000000000..ca462a5758 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_incomplete_array_header.data @@ -0,0 +1,15 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]3 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method3_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method3_params + +[anchr]param0_ptr +[u4]16 // num_bytes: Incomplete array header. diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_incomplete_array_header.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_incomplete_array_header.expected new file mode 100644 index 0000000000..779df88cf6 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_incomplete_array_header.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_ILLEGAL_MEMORY_RANGE diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_misaligned_array.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_misaligned_array.data new file mode 100644 index 0000000000..5adfbbaa97 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_misaligned_array.data @@ -0,0 +1,21 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]3 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method3_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method3_params + +[u2]0 // Causes the following array to be misaligned. + +[anchr]param0_ptr +[dist4]array // num_bytes +[u4]12 // num_elements +[b]01010101 +[b]00001111 +[anchr]array diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_misaligned_array.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_misaligned_array.expected new file mode 100644 index 0000000000..acca999b3f --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_misaligned_array.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_MISALIGNED_OBJECT diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_unexpected_null_array.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_unexpected_null_array.data new file mode 100644 index 0000000000..0f96c4bd58 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_unexpected_null_array.data @@ -0,0 +1,12 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]3 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method3_params // num_bytes +[u4]0 // version +[u8]0 // param0: An unexpected null pointer. +[anchr]method3_params diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_unexpected_null_array.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_unexpected_null_array.expected new file mode 100644 index 0000000000..95d8db01bb --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd3_unexpected_null_array.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_NULL_POINTER diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd4_good.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd4_good.data new file mode 100644 index 0000000000..84943d29ec --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd4_good.data @@ -0,0 +1,34 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]4 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method4_params // num_bytes: Larger than what we know is okay. +[u4]3 // version: Larger than what we know is okay. +[dist8]param0_ptr // param0 +[dist8]param1_ptr // param1 +[u8]0 // unknown +[anchr]method4_params + +[anchr]param0_ptr +[dist4]struct_c // num_bytes +[u4]0 // version +[dist8]array_ptr // array +[anchr]struct_c + +[anchr]array_ptr +[dist4]array_member // num_bytes +[u4]3 // num_elements +0 1 2 +[anchr]array_member + +[u4]0 [u1]0 // Padding to make the next array aligned properly. + +[anchr]param1_ptr +[dist4]array_param // num_bytes +[u4]10 // num_elements +0 1 2 3 4 5 6 7 8 9 +[anchr]array_param diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd4_good.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd4_good.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd4_good.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd4_multiple_pointers_to_same_array.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd4_multiple_pointers_to_same_array.data new file mode 100644 index 0000000000..2f84185552 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd4_multiple_pointers_to_same_array.data @@ -0,0 +1,26 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]4 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method4_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[dist8]param1_ptr // param1 +[anchr]method4_params + +[anchr]param0_ptr +[dist4]struct_c // num_bytes +[u4]0 // version +[dist8]array_ptr // array +[anchr]struct_c + +[anchr]param1_ptr +[anchr]array_ptr +[dist4]array_member // num_bytes +[u4]3 // num_elements +0 1 2 +[anchr]array_member diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd4_multiple_pointers_to_same_array.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd4_multiple_pointers_to_same_array.expected new file mode 100644 index 0000000000..779df88cf6 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd4_multiple_pointers_to_same_array.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_ILLEGAL_MEMORY_RANGE diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd4_overlapped_objects.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd4_overlapped_objects.data new file mode 100644 index 0000000000..d863e64a12 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd4_overlapped_objects.data @@ -0,0 +1,32 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]4 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method4_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[dist8]param1_ptr // param1 +[anchr]method4_params + +[anchr]param0_ptr +[dist4]struct_c // num_bytes +[u4]0 // version +[dist8]array_ptr // array +[anchr]struct_c + +[anchr]array_ptr +[dist4]array_member // num_bytes +[u4]3 // num_elements + +[anchr]param1_ptr +// The first three bytes of |num_bytes| are also the elements of the previous +// array. +[dist4]array_param // num_bytes +[u4]10 // num_elements +0 1 2 3 4 5 6 7 8 9 +[anchr]array_param +[anchr]array_member diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd4_overlapped_objects.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd4_overlapped_objects.expected new file mode 100644 index 0000000000..779df88cf6 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd4_overlapped_objects.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_ILLEGAL_MEMORY_RANGE diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd4_wrong_layout_order.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd4_wrong_layout_order.data new file mode 100644 index 0000000000..b61423a6d7 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd4_wrong_layout_order.data @@ -0,0 +1,35 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]4 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method4_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[dist8]param1_ptr // param1 +[anchr]method4_params + +[anchr]param0_ptr +[dist4]struct_c // num_bytes +[u4]0 // version +[dist8]array_ptr // array +[anchr]struct_c + +// The following two arrays are arranged in wrong order. + +[anchr]param1_ptr +[dist4]array_param // num_bytes +[u4]10 // num_elements +0 1 2 3 4 5 6 7 8 9 +[anchr]array_param + +[u4]0 [u2]0 // Padding to make the next array aligned properly. + +[anchr]array_ptr +[dist4]array_member // num_bytes +[u4]3 // num_elements +0 1 2 +[anchr]array_member diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd4_wrong_layout_order.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd4_wrong_layout_order.expected new file mode 100644 index 0000000000..779df88cf6 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd4_wrong_layout_order.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_ILLEGAL_MEMORY_RANGE diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_good.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_good.data new file mode 100644 index 0000000000..dcec8952d1 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_good.data @@ -0,0 +1,37 @@ +[handles]10 // Larger than the number of handles that we know about is okay. + +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]5 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method5_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[u4]4 // param1 +[u4]0 // padding +[anchr]method5_params + +[anchr]param0_ptr +[dist4]struct_e // num_bytes +[u4]0 // version +[dist8]struct_d_ptr // struct_d +[u4]3 // data_pipe_consumer +[u4]0 // padding +[anchr]struct_e + +[anchr]struct_d_ptr +[dist4]struct_d // num_bytes +[u4]0 // version +[dist8]message_pipes_ptr // message_pipes +[anchr]struct_d + +[anchr]message_pipes_ptr +[dist4]message_pipe_array // num_bytes +[u4]2 // num_elements +[u4]0 +[u4]1 +[anchr]message_pipe_array diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_good.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_good.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_good.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_handle_out_of_range.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_handle_out_of_range.data new file mode 100644 index 0000000000..d4a82ed174 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_handle_out_of_range.data @@ -0,0 +1,38 @@ +[handles]10 + +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]5 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method5_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[u4]10 // param1: It is outside of the valid encoded handle + // range [0, 10). +[u4]0 // padding +[anchr]method5_params + +[anchr]param0_ptr +[dist4]struct_e // num_bytes +[u4]0 // version +[dist8]struct_d_ptr // struct_d +[u4]3 // data_pipe_consumer +[u4]0 // padding +[anchr]struct_e + +[anchr]struct_d_ptr +[dist4]struct_d // num_bytes +[u4]0 // version +[dist8]message_pipes_ptr // message_pipes +[anchr]struct_d + +[anchr]message_pipes_ptr +[dist4]message_pipe_array // num_bytes +[u4]2 // num_elements +[u4]0 +[u4]1 +[anchr]message_pipe_array diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_handle_out_of_range.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_handle_out_of_range.expected new file mode 100644 index 0000000000..eef8e38a84 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_handle_out_of_range.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_ILLEGAL_HANDLE diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_multiple_handles_with_same_value_1.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_multiple_handles_with_same_value_1.data new file mode 100644 index 0000000000..9ee7a48c9c --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_multiple_handles_with_same_value_1.data @@ -0,0 +1,37 @@ +[handles]10 + +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]5 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method5_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[u4]4 // param1 +[u4]0 // padding +[anchr]method5_params + +[anchr]param0_ptr +[dist4]struct_e // num_bytes +[u4]0 // version +[dist8]struct_d_ptr // struct_d +[u4]4 // data_pipe_consumer: The same value as |param1| above. +[u4]0 // padding +[anchr]struct_e + +[anchr]struct_d_ptr +[dist4]struct_d // num_bytes +[u4]0 // version +[dist8]message_pipes_ptr // message_pipes +[anchr]struct_d + +[anchr]message_pipes_ptr +[dist4]message_pipe_array // num_bytes +[u4]2 // num_elements +[u4]0 +[u4]1 +[anchr]message_pipe_array diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_multiple_handles_with_same_value_1.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_multiple_handles_with_same_value_1.expected new file mode 100644 index 0000000000..eef8e38a84 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_multiple_handles_with_same_value_1.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_ILLEGAL_HANDLE diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_multiple_handles_with_same_value_2.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_multiple_handles_with_same_value_2.data new file mode 100644 index 0000000000..cb01caeb1a --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_multiple_handles_with_same_value_2.data @@ -0,0 +1,37 @@ +[handles]10 + +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]5 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method5_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[u4]4 // param1 +[u4]0 // padding +[anchr]method5_params + +[anchr]param0_ptr +[dist4]struct_e // num_bytes +[u4]0 // version +[dist8]struct_d_ptr // struct_d +[u4]3 // data_pipe_consumer +[u4]0 // padding +[anchr]struct_e + +[anchr]struct_d_ptr +[dist4]struct_d // num_bytes +[u4]0 // version +[dist8]message_pipes_ptr // message_pipes +[anchr]struct_d + +[anchr]message_pipes_ptr +[dist4]message_pipe_array // num_bytes +[u4]2 // num_elements +[u4]1 // The two message pipe handles have the same value. +[u4]1 +[anchr]message_pipe_array diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_multiple_handles_with_same_value_2.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_multiple_handles_with_same_value_2.expected new file mode 100644 index 0000000000..eef8e38a84 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_multiple_handles_with_same_value_2.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_ILLEGAL_HANDLE diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_unexpected_invalid_handle.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_unexpected_invalid_handle.data new file mode 100644 index 0000000000..b06ae0a46b --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_unexpected_invalid_handle.data @@ -0,0 +1,36 @@ +[handles]5 + +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]5 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method5_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[u4]4 // param1 +[u4]0 // padding +[anchr]method5_params + +[anchr]param0_ptr +[dist4]struct_e // num_bytes +[u4]0 // version +[dist8]struct_d_ptr // struct_d +[s4]-1 // data_pipe_consumer: An unexpected invalid handle. +[u4]0 // padding +[anchr]struct_e + +[anchr]struct_d_ptr +[dist4]struct_d // num_bytes +[u4]0 // version +[dist8]message_pipes_ptr // message_pipes +[anchr]struct_d + +[anchr]message_pipes_ptr +[dist4]message_pipe_array // num_bytes +[u4]1 // num_elements +[u4]2 +[anchr]message_pipe_array diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_unexpected_invalid_handle.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_unexpected_invalid_handle.expected new file mode 100644 index 0000000000..6768236f6e --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_unexpected_invalid_handle.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_INVALID_HANDLE diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_wrong_handle_order.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_wrong_handle_order.data new file mode 100644 index 0000000000..f641de0561 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_wrong_handle_order.data @@ -0,0 +1,38 @@ +[handles]10 + +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]5 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method5_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[u4]9 // param1 +[u4]0 // padding +[anchr]method5_params + +[anchr]param0_ptr +[dist4]struct_e // num_bytes +[u4]0 // version +[dist8]struct_d_ptr // struct_d +[u4]1 // data_pipe_consumer: It is smaller than those handles + // in |message_pipe_array|, which is wrong. +[u4]0 // padding +[anchr]struct_e + +[anchr]struct_d_ptr +[dist4]struct_d // num_bytes +[u4]0 // version +[dist8]message_pipes_ptr // message_pipes +[anchr]struct_d + +[anchr]message_pipes_ptr +[dist4]message_pipe_array // num_bytes +[u4]2 // num_elements +[u4]3 +[u4]4 +[anchr]message_pipe_array diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_wrong_handle_order.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_wrong_handle_order.expected new file mode 100644 index 0000000000..eef8e38a84 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd5_wrong_handle_order.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_ILLEGAL_HANDLE diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd6_good.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd6_good.data new file mode 100644 index 0000000000..fb3f862f4c --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd6_good.data @@ -0,0 +1,24 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]6 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method6_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method6_params + +[anchr]param0_ptr +[dist4]array_param // num_bytes +[u4]1 // num_elements +[dist8]element_ptr +[anchr]array_param + +[anchr]element_ptr +[dist4]array_element // num_bytes +[u4]10 // num_elements +0 1 2 3 4 5 6 7 8 9 +[anchr]array_element diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd6_good.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd6_good.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd6_good.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd6_nested_array_num_bytes_less_than_necessary_size.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd6_nested_array_num_bytes_less_than_necessary_size.data new file mode 100644 index 0000000000..c8cacf0b2e --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd6_nested_array_num_bytes_less_than_necessary_size.data @@ -0,0 +1,24 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]6 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method6_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method6_params + +[anchr]param0_ptr +[dist4]array_param // num_bytes +[u4]1 // num_elements +[dist8]element_ptr +[anchr]array_param + +[anchr]element_ptr +[dist4]array_element // num_bytes: It is insufficient to store 12 elements. +[u4]12 // num_elements +0 1 2 3 4 5 6 7 8 9 +[anchr]array_element diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd6_nested_array_num_bytes_less_than_necessary_size.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd6_nested_array_num_bytes_less_than_necessary_size.expected new file mode 100644 index 0000000000..5a1ec4ef20 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd6_nested_array_num_bytes_less_than_necessary_size.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_ARRAY_HEADER diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd7_good.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd7_good.data new file mode 100644 index 0000000000..c9726763e1 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd7_good.data @@ -0,0 +1,40 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]7 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method7_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[dist8]param1_ptr // param1 +[anchr]method7_params + +[anchr]param0_ptr +[dist4]struct_f // num_bytes +[u4]0 // version +[dist8]array_ptr // fixed_size_array +[anchr]struct_f + +[anchr]array_ptr +[dist4]array_member // num_bytes +[u4]3 // num_elements +0 1 2 +[anchr]array_member + +[u4]0 [u1]0 // Padding to make the next array aligned properly. + +[anchr]param1_ptr +[dist4]array_param // num_bytes +[u4]2 // num_elements +[u8]0 // A null pointer, which is okay. +[dist8]array_element_ptr +[anchr]array_param + +[anchr]array_element_ptr +[dist4]array_element // num_bytes +[u4]3 // num_elements +0 1 2 +[anchr]array_element diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd7_good.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd7_good.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd7_good.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd7_unexpected_null_fixed_array.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd7_unexpected_null_fixed_array.data new file mode 100644 index 0000000000..4d25cf24a2 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd7_unexpected_null_fixed_array.data @@ -0,0 +1,26 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]7 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method7_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[dist8]param1_ptr // param1 +[anchr]method7_params + +[anchr]param0_ptr +[dist4]struct_f // num_bytes +[u4]0 // version +[u8]0 // fixed_size_array: An unexpected null pointer. +[anchr]struct_f + +[anchr]param1_ptr +[dist4]array_param // num_bytes +[u4]2 // num_elements +[u8]0 // A null pointer, which is okay. +[u8]0 // A null pointer, which is okay. +[anchr]array_param diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd7_unexpected_null_fixed_array.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd7_unexpected_null_fixed_array.expected new file mode 100644 index 0000000000..95d8db01bb --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd7_unexpected_null_fixed_array.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_NULL_POINTER diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd7_unmatched_array_elements.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd7_unmatched_array_elements.data new file mode 100644 index 0000000000..cee6e1404f --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd7_unmatched_array_elements.data @@ -0,0 +1,34 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]7 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method7_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[dist8]param1_ptr // param1 +[anchr]method7_params + +[anchr]param0_ptr +[dist4]struct_f // num_bytes +[u4]0 // version +[dist8]array_ptr // fixed_size_array +[anchr]struct_f + +[anchr]array_ptr +[dist4]array_member // num_bytes +[u4]2 // num_elements: Too few elements. +0 1 +[anchr]array_member + +[u4]0 [u1]0 [u1]0 // Padding for alignment of next array. + +[anchr]param1_ptr +[dist4]array_param // num_bytes +[u4]2 // num_elements +[u8]0 // A null pointer, which is okay. +[u8]0 // A null pointer, which is okay. +[anchr]array_param diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd7_unmatched_array_elements.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd7_unmatched_array_elements.expected new file mode 100644 index 0000000000..5a1ec4ef20 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd7_unmatched_array_elements.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_ARRAY_HEADER diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd7_unmatched_array_elements_nested.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd7_unmatched_array_elements_nested.data new file mode 100644 index 0000000000..3095a73893 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd7_unmatched_array_elements_nested.data @@ -0,0 +1,40 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]7 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method7_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[dist8]param1_ptr // param1 +[anchr]method7_params + +[anchr]param0_ptr +[dist4]struct_f // num_bytes +[u4]0 // version +[dist8]array_ptr // fixed_size_array +[anchr]struct_f + +[anchr]array_ptr +[dist4]array_member // num_bytes +[u4]3 // num_elements +0 1 3 +[anchr]array_member + +[u4]0 [u1]0 // Padding for alignment of next array. + +[anchr]param1_ptr +[dist4]array_param // num_bytes +[u4]2 // num_elements +[dist8]array_element_ptr +[u8]0 // A null pointer, which is okay. +[anchr]array_param + +[anchr]array_element_ptr +[dist4]array_element // num_bytes +[u4]4 // num_elements: Too many elements. +0 1 2 3 +[anchr]array_element diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd7_unmatched_array_elements_nested.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd7_unmatched_array_elements_nested.expected new file mode 100644 index 0000000000..5a1ec4ef20 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd7_unmatched_array_elements_nested.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_ARRAY_HEADER diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd8_array_num_bytes_overflow.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd8_array_num_bytes_overflow.data new file mode 100644 index 0000000000..b19e141b0b --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd8_array_num_bytes_overflow.data @@ -0,0 +1,21 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]8 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method8_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method8_params + +[anchr]param0_ptr +[dist4]array_param // num_bytes +[u4]0x20000001 // num_elements: The corresponding array size should be + // 0x20000001 * 8 + 8 = 0x100000010 which is + // 2^32 + 16 (base-10), while |num_bytes| is a 32-bit + // unsigned integer and its value is 16. +[u8]0 +[anchr]array_param diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd8_array_num_bytes_overflow.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd8_array_num_bytes_overflow.expected new file mode 100644 index 0000000000..5a1ec4ef20 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd8_array_num_bytes_overflow.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_ARRAY_HEADER diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd8_good.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd8_good.data new file mode 100644 index 0000000000..08c4bc3121 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd8_good.data @@ -0,0 +1,32 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]8 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method8_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method8_params + +[anchr]param0_ptr +[dist4]array_param // num_bytes +[u4]3 // num_elements +[u8]0 // A null pointer, which is okay. +[dist8]nested_array_ptr +[u8]0 // A null pointer, which is okay. +[anchr]array_param + +[anchr]nested_array_ptr +[dist4]nested_array // num_bytes +[u4]1 // num_elements +[dist8]string_ptr +[anchr]nested_array + +[anchr]string_ptr +[dist4]string // num_bytes +[u4]5 // num_elements +0 1 2 3 4 +[anchr]string diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd8_good.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd8_good.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd8_good.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd8_unexpected_null_array.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd8_unexpected_null_array.data new file mode 100644 index 0000000000..03f2a10cb5 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd8_unexpected_null_array.data @@ -0,0 +1,12 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]8 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method8_params // num_bytes +[u4]0 // version +[u8]0 // param0: An unexpected null pointer. +[anchr]method8_params diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd8_unexpected_null_array.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd8_unexpected_null_array.expected new file mode 100644 index 0000000000..95d8db01bb --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd8_unexpected_null_array.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_NULL_POINTER diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd8_unexpected_null_string.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd8_unexpected_null_string.data new file mode 100644 index 0000000000..b1b4462051 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd8_unexpected_null_string.data @@ -0,0 +1,33 @@ +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]8 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method8_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method8_params + +[anchr]param0_ptr +[dist4]array_param // num_bytes +[u4]3 // num_elements +[u8]0 // A null pointer, which is okay. +[dist8]nested_array_ptr +[u8]0 // A null pointer, which is okay. +[anchr]array_param + +[anchr]nested_array_ptr +[dist4]nested_array // num_bytes +[u4]2 // num_elements +[dist8]string_ptr +[u8]0 // An unexpected null pointer. +[anchr]nested_array + +[anchr]string_ptr +[dist4]string // num_bytes +[u4]5 // num_elements +0 1 2 3 4 +[anchr]string diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd8_unexpected_null_string.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd8_unexpected_null_string.expected new file mode 100644 index 0000000000..95d8db01bb --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd8_unexpected_null_string.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_NULL_POINTER diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd9_good.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd9_good.data new file mode 100644 index 0000000000..6ed00092c6 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd9_good.data @@ -0,0 +1,36 @@ +[handles]4 + +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]9 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method9_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method9_params + +[anchr]param0_ptr +[dist4]array_param // num_bytes +[u4]2 // num_elements +[dist8]nested_array_ptr_0 +[dist8]nested_array_ptr_1 +[anchr]array_param + +[anchr]nested_array_ptr_0 +[dist4]nested_array_0 // num_bytes +[u4]2 // num_elements +[u4]0 +[s4]-1 // An invalid handle, which is okay. +[anchr]nested_array_0 + +[anchr]nested_array_ptr_1 +[dist4]nested_array_1 // num_bytes +[u4]3 // num_elements +[u4]2 +[s4]-1 // An invalid handle, which is okay. +[u4]3 +[anchr]nested_array_1 diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd9_good.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd9_good.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd9_good.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd9_good_null_array.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd9_good_null_array.data new file mode 100644 index 0000000000..90feced0b6 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd9_good_null_array.data @@ -0,0 +1,14 @@ +[handles]4 + +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]9 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method9_params // num_bytes +[u4]0 // version +[u8]0 // param0: A null pointer, which is okay. +[anchr]method9_params diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd9_good_null_array.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd9_good_null_array.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd9_good_null_array.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd9_unexpected_null_array.data b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd9_unexpected_null_array.data new file mode 100644 index 0000000000..e87fbcba31 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd9_unexpected_null_array.data @@ -0,0 +1,27 @@ +[handles]4 + +[dist4]message_header // num_bytes +[u4]0 // version +[u4]0 // interface ID +[u4]9 // name +[u4]0 // flags +[u4]0 // padding +[anchr]message_header + +[dist4]method9_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method9_params + +[anchr]param0_ptr +[dist4]array_param // num_bytes +[u4]2 // num_elements +[dist8]nested_array_ptr_0 +[u8]0 // An unexpected null pointer. +[anchr]array_param + +[anchr]nested_array_ptr_0 +[dist4]nested_array_0 // num_bytes +[u4]1 // num_elements +[u4]0 +[anchr]nested_array_0 diff --git a/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd9_unexpected_null_array.expected b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd9_unexpected_null_array.expected new file mode 100644 index 0000000000..95d8db01bb --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/conformance_mthd9_unexpected_null_array.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_NULL_POINTER diff --git a/mojo/public/interfaces/bindings/tests/data/validation/integration_intf_resp_mthd0_good.data b/mojo/public/interfaces/bindings/tests/data/validation/integration_intf_resp_mthd0_good.data new file mode 100644 index 0000000000..7da356fc5e --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/integration_intf_resp_mthd0_good.data @@ -0,0 +1,19 @@ +[dist4]message_header // num_bytes +[u4]1 // version +[u4]0 // interface ID +[u4]0 // name +[u4]2 // flags kMessageIsResponse +[u4]0 // padding +[u8]1 // request_id +[anchr]message_header + +[dist4]method0_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method0_params + +[anchr]param0_ptr +[dist4]uint8_array // num_bytes +[u4]1 // num_elements +[u1]0 +[anchr]uint8_array diff --git a/mojo/public/interfaces/bindings/tests/data/validation/integration_intf_resp_mthd0_good.expected b/mojo/public/interfaces/bindings/tests/data/validation/integration_intf_resp_mthd0_good.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/integration_intf_resp_mthd0_good.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/integration_intf_resp_mthd0_unexpected_array_header.data b/mojo/public/interfaces/bindings/tests/data/validation/integration_intf_resp_mthd0_unexpected_array_header.data new file mode 100644 index 0000000000..bdcfc46853 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/integration_intf_resp_mthd0_unexpected_array_header.data @@ -0,0 +1,19 @@ +[dist4]message_header // num_bytes +[u4]1 // version +[u4]0 // interface ID +[u4]0 // name +[u4]2 // flags kMessageIsResponse +[u4]0 // padding +[u8]1 // request_id +[anchr]message_header + +[dist4]method0_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method0_params + +[anchr]param0_ptr +[dist4]uint8_array // num_bytes +[u4]2 // num_elements: The size is too small to hold 2 elements. +[u1]0 +[anchr]uint8_array diff --git a/mojo/public/interfaces/bindings/tests/data/validation/integration_intf_resp_mthd0_unexpected_array_header.expected b/mojo/public/interfaces/bindings/tests/data/validation/integration_intf_resp_mthd0_unexpected_array_header.expected new file mode 100644 index 0000000000..5a1ec4ef20 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/integration_intf_resp_mthd0_unexpected_array_header.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_ARRAY_HEADER diff --git a/mojo/public/interfaces/bindings/tests/data/validation/integration_intf_rqst_mthd0_good.data b/mojo/public/interfaces/bindings/tests/data/validation/integration_intf_rqst_mthd0_good.data new file mode 100644 index 0000000000..a1fe69d82e --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/integration_intf_rqst_mthd0_good.data @@ -0,0 +1,20 @@ +[dist4]message_header // num_bytes +[u4]1 // version +[u4]0 // interface ID +[u4]0 // name +[u4]1 // flags kMessageExpectsResponse +[u4]0 // padding +[u8]7 // request_id +[anchr]message_header + +[dist4]method0_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method0_params + +[anchr]param0_ptr +[dist4]basic_struct // num_bytes +[u4]0 // version +[s4]-1 // a +[u4]0 // padding +[anchr]basic_struct diff --git a/mojo/public/interfaces/bindings/tests/data/validation/integration_intf_rqst_mthd0_good.expected b/mojo/public/interfaces/bindings/tests/data/validation/integration_intf_rqst_mthd0_good.expected new file mode 100644 index 0000000000..7ef22e9a43 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/integration_intf_rqst_mthd0_good.expected @@ -0,0 +1 @@ +PASS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/integration_intf_rqst_mthd0_unexpected_struct_header.data b/mojo/public/interfaces/bindings/tests/data/validation/integration_intf_rqst_mthd0_unexpected_struct_header.data new file mode 100644 index 0000000000..e689adb670 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/integration_intf_rqst_mthd0_unexpected_struct_header.data @@ -0,0 +1,17 @@ +[dist4]message_header // num_bytes +[u4]1 // version +[u4]0 // interface ID +[u4]0 // name +[u4]1 // flags kMessageExpectsResponse +[u4]0 // padding +[u8]7 // request_id +[anchr]message_header + +[dist4]method0_params // num_bytes +[u4]0 // version +[dist8]param0_ptr // param0 +[anchr]method0_params + +[anchr]param0_ptr +[u4]0 // num_bytes: The struct size is too small. +[u4]0 // version diff --git a/mojo/public/interfaces/bindings/tests/data/validation/integration_intf_rqst_mthd0_unexpected_struct_header.expected b/mojo/public/interfaces/bindings/tests/data/validation/integration_intf_rqst_mthd0_unexpected_struct_header.expected new file mode 100644 index 0000000000..25aceeea5a --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/integration_intf_rqst_mthd0_unexpected_struct_header.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_UNEXPECTED_STRUCT_HEADER diff --git a/mojo/public/interfaces/bindings/tests/data/validation/integration_msghdr_invalid_flags.data b/mojo/public/interfaces/bindings/tests/data/validation/integration_msghdr_invalid_flags.data new file mode 100644 index 0000000000..7198afa30e --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/integration_msghdr_invalid_flags.data @@ -0,0 +1,8 @@ +[dist4]message_header // num_bytes +[u4]1 // version +[u4]0 // interface ID +[u4]0xffffffff // name +[u4]3 // flags: This combination is illegal. +[u4]0 // padding +[u8]1 // request_id +[anchr]message_header diff --git a/mojo/public/interfaces/bindings/tests/data/validation/integration_msghdr_invalid_flags.expected b/mojo/public/interfaces/bindings/tests/data/validation/integration_msghdr_invalid_flags.expected new file mode 100644 index 0000000000..c33fde327b --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/integration_msghdr_invalid_flags.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_MESSAGE_HEADER_INVALID_FLAGS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/resp_boundscheck_msghdr_no_such_method.data b/mojo/public/interfaces/bindings/tests/data/validation/resp_boundscheck_msghdr_no_such_method.data new file mode 100644 index 0000000000..72835098f7 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/resp_boundscheck_msghdr_no_such_method.data @@ -0,0 +1,8 @@ +[dist4]message_header // num_bytes +[u4]1 // version +[u4]0 // interface ID +[u4]1 // name: Method1 does not have a response message. +[u4]2 // flags: kMessageIsResponse +[u4]0 // padding +[u8]1 // request_id +[anchr]message_header diff --git a/mojo/public/interfaces/bindings/tests/data/validation/resp_boundscheck_msghdr_no_such_method.expected b/mojo/public/interfaces/bindings/tests/data/validation/resp_boundscheck_msghdr_no_such_method.expected new file mode 100644 index 0000000000..65a48b3c06 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/resp_boundscheck_msghdr_no_such_method.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_MESSAGE_HEADER_UNKNOWN_METHOD
\ No newline at end of file diff --git a/mojo/public/interfaces/bindings/tests/data/validation/resp_conformance_msghdr_invalid_response_flags1.data b/mojo/public/interfaces/bindings/tests/data/validation/resp_conformance_msghdr_invalid_response_flags1.data new file mode 100644 index 0000000000..d1d8d3f157 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/resp_conformance_msghdr_invalid_response_flags1.data @@ -0,0 +1,8 @@ +[dist4]message_header // num_bytes +[u4]1 // version +[u4]0 // interface ID +[u4]12 // name +[u4]0 // flags: kMessageIsResponse is not set in a response. +[u4]0 // padding +[u8]1 // request_id +[anchr]message_header diff --git a/mojo/public/interfaces/bindings/tests/data/validation/resp_conformance_msghdr_invalid_response_flags1.expected b/mojo/public/interfaces/bindings/tests/data/validation/resp_conformance_msghdr_invalid_response_flags1.expected new file mode 100644 index 0000000000..c33fde327b --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/resp_conformance_msghdr_invalid_response_flags1.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_MESSAGE_HEADER_INVALID_FLAGS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/resp_conformance_msghdr_invalid_response_flags2.data b/mojo/public/interfaces/bindings/tests/data/validation/resp_conformance_msghdr_invalid_response_flags2.data new file mode 100644 index 0000000000..091b68c235 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/resp_conformance_msghdr_invalid_response_flags2.data @@ -0,0 +1,8 @@ +[dist4]message_header // num_bytes +[u4]1 // version +[u4]0 // interface ID +[u4]12 // name +[u4]1 // flags: kMessageExpectsResponse is set in a response. +[u4]0 // padding +[u8]1 // request_id +[anchr]message_header diff --git a/mojo/public/interfaces/bindings/tests/data/validation/resp_conformance_msghdr_invalid_response_flags2.expected b/mojo/public/interfaces/bindings/tests/data/validation/resp_conformance_msghdr_invalid_response_flags2.expected new file mode 100644 index 0000000000..c33fde327b --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/resp_conformance_msghdr_invalid_response_flags2.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_MESSAGE_HEADER_INVALID_FLAGS diff --git a/mojo/public/interfaces/bindings/tests/data/validation/resp_conformance_msghdr_no_such_method.data b/mojo/public/interfaces/bindings/tests/data/validation/resp_conformance_msghdr_no_such_method.data new file mode 100644 index 0000000000..0eda287e32 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/resp_conformance_msghdr_no_such_method.data @@ -0,0 +1,8 @@ +[dist4]message_header // num_bytes +[u4]1 // version +[u4]0 // interface ID +[u4]11 // name: Method11 does not have a response message. +[u4]2 // flags: kMessageIsResponse +[u4]0 // padding +[u8]1 // request_id +[anchr]message_header diff --git a/mojo/public/interfaces/bindings/tests/data/validation/resp_conformance_msghdr_no_such_method.expected b/mojo/public/interfaces/bindings/tests/data/validation/resp_conformance_msghdr_no_such_method.expected new file mode 100644 index 0000000000..65a48b3c06 --- /dev/null +++ b/mojo/public/interfaces/bindings/tests/data/validation/resp_conformance_msghdr_no_such_method.expected @@ -0,0 +1 @@ +VALIDATION_ERROR_MESSAGE_HEADER_UNKNOWN_METHOD
\ No newline at end of file |