// AUTOGENERATED FILE mod test_utils; mod tests { use insta::{assert_debug_snapshot, with_settings}; use crate::test_utils::*; // Spec valid tests #[test] fn dbl_quote_after_ampersand_in_double_hyphen_quoted_attribute_value() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn apos1_after_ampersand_in_double_hyphen_quoted_attribute_value() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn apos1_after_ampersand_in_single_hyphen_quoted_attribute_value() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn dbl_quote_after_ampersand_in_single_hyphen_quoted_attribute_value() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn text_after_bogus_character_reference() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####"bar"####)); }); } #[test] fn text_after_hex_character_reference() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####"bar"####)); }); } #[test] fn quoted_attribute_followed_by_permitted() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####"
"####)); }); } #[test] fn quoted_attribute_followed_by_non_hyphen_permitted() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn zero_hyphen_prefixed_hex_numeric_entity() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####"A"####)); }); } #[test] fn zero_hyphen_prefixed_decimal_numeric_entity() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####"A"####)); }); } #[test] fn non_hyphen_bmp_numeric_entity() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####"𐀀"####)); }); } #[test] fn uppercase_start_tag_name() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn uppercase_end_tag_name() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn uppercase_attribute_name() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn tag_attribute_name_case_edge_values() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn permitted_slash() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####"
"####)); }); } #[test] fn non_hyphen_permitted_slash() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn doctype_public_case_hyphen_sensitivity_1() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn doctype_public_case_hyphen_sensitivity_2() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn doctype_system_case_hyphen_sensitivity_1() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn doctype_system_case_hyphen_sensitivity_2() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn cr_followed_by_non_hyphen_lf() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####" ?"####)); }); } #[test] fn cr_at_eof() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####" "####)); }); } #[test] fn lf_at_eof() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####" "####)); }); } #[test] fn cr_lf() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####" "####)); }); } #[test] fn cr_cr() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####" "####)); }); } #[test] fn lf_lf() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####" "####)); }); } #[test] fn lf_cr() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####" "####)); }); } #[test] fn text_cr_cr_cr_text() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####"text text"####)); }); } // Spec error tests #[test] fn lt_in_attribute_name() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn lt_in_unquoted_attribute_value() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn equals_in_unquoted_attribute_value() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn equals_attribute() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn equals_equals_attribute() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn equals_equals_equals_attribute() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn equals_equals_equals_equals_attribute() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn attribute_name_starting_with_dbl_quote() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn attribute_name_starting_with_apos1() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn attribute_name_containing_dbl_quote() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn attribute_name_containing_apos1() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn unquoted_attribute_value_containing_apos1() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn unquoted_attribute_value_containing_dbl_quote() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn double_hyphen_quoted_attribute_value_not_followed_by_whitespace() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn single_hyphen_quoted_attribute_value_not_followed_by_whitespace() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn cr_eof_after_doctype_name() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####"true}, { assert_debug_snapshot!(parser_test(r####"true}, { assert_debug_snapshot!(parser_test(r####"true}, { assert_debug_snapshot!(parser_test(r####"�"####)); }); } #[test] fn zero_decimal_numeric_entity() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####"�"####)); }); } #[test] fn empty_hex_numeric_entities() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####"&#x &#X "####)); }); } #[test] fn invalid_digit_in_hex_numeric_entity() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####"&#xZ"####)); }); } #[test] fn empty_decimal_numeric_entities() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####"&# &#; "####)); }); } #[test] fn invalid_digit_in_decimal_numeric_entity() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####"&#A"####)); }); } #[test] fn maximum_non_hyphen_bmp_numeric_entity() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####"􏿿"####)); }); } #[test] fn above_maximum_numeric_entity() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####"�"####)); }); } #[test] fn num_32_hyphen_bit_hex_numeric_entity() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####"�"####)); }); } #[test] fn num_33_hyphen_bit_hex_numeric_entity() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####"�"####)); }); } #[test] fn num_33_hyphen_bit_decimal_numeric_entity() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####"�"####)); }); } #[test] fn num_65_hyphen_bit_hex_numeric_entity() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####"�"####)); }); } #[test] fn num_65_hyphen_bit_decimal_numeric_entity() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####"�"####)); }); } #[test] fn surrogate_code_point_edge_cases() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####"퟿����"####)); }); } #[test] fn duplicate_different_hyphen_case_attributes() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn uppercase_close_tag_attributes() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn duplicate_close_tag_attributes() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####"
"####)); }); } #[test] fn permitted_slash_but_in_close_tag() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####"
"####)); }); } #[test] fn u_plus_0000_in_lookahead_region_after_non_hyphen_matching_character() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn u_plus_0000_in_lookahead_region() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####"true}, { assert_debug_snapshot!(parser_test(r####"true}, { assert_debug_snapshot!(parser_test(r####"true}, { assert_debug_snapshot!(parser_test(r####"true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn doctype_publi() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####"true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn doctype_sys() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####"true}, { assert_debug_snapshot!(parser_test(r####"text"####)); }); } #[test] fn grave_accent_in_unquoted_attribute() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####""####)); }); } #[test] fn eof_in_tag_name_state() { with_settings!({sort_maps =>true}, { assert_debug_snapshot!(parser_test(r####"true}, { assert_debug_snapshot!(parser_test(r####"true}, { assert_debug_snapshot!(parser_test(r####"true}, { assert_debug_snapshot!(parser_test(r####"true}, { assert_debug_snapshot!(parser_test(r####"true}, { assert_debug_snapshot!(parser_test(r####"