diff options
author | Markus Unterwaditzer <markus-honeypot@unterwaditzer.net> | 2021-11-24 20:44:08 +0100 |
---|---|---|
committer | Markus Unterwaditzer <markus-honeypot@unterwaditzer.net> | 2021-11-24 20:51:21 +0100 |
commit | 9909fc4580855a58a10eb84f0d143d1b3b3f464a (patch) | |
tree | 36941a6a714a10b9ce554ba249975108e6a17274 /tests/html5lib-tests/tokenizer/escapeFlag.test |
hello world
Diffstat (limited to 'tests/html5lib-tests/tokenizer/escapeFlag.test')
-rw-r--r-- | tests/html5lib-tests/tokenizer/escapeFlag.test | 36 |
1 files changed, 36 insertions, 0 deletions
diff --git a/tests/html5lib-tests/tokenizer/escapeFlag.test b/tests/html5lib-tests/tokenizer/escapeFlag.test new file mode 100644 index 0000000..d7d2c49 --- /dev/null +++ b/tests/html5lib-tests/tokenizer/escapeFlag.test @@ -0,0 +1,36 @@ +{"tests": [ + +{"description":"Commented close tag in RCDATA or RAWTEXT", +"initialStates":["RCDATA state", "RAWTEXT state"], +"lastStartTag":"xmp", +"input":"foo<!--</xmp>--></xmp>", +"output":[["Character", "foo<!--"], ["EndTag", "xmp"], ["Character", "-->"], ["EndTag", "xmp"]]}, + +{"description":"Bogus comment in RCDATA or RAWTEXT", +"initialStates":["RCDATA state", "RAWTEXT state"], +"lastStartTag":"xmp", +"input":"foo<!-->baz</xmp>", +"output":[["Character", "foo<!-->baz"], ["EndTag", "xmp"]]}, + +{"description":"End tag surrounded by bogus comment in RCDATA or RAWTEXT", +"initialStates":["RCDATA state", "RAWTEXT state"], +"lastStartTag":"xmp", +"input":"foo<!--></xmp><!-->baz</xmp>", +"output":[["Character", "foo<!-->"], ["EndTag", "xmp"], ["Comment", ""], ["Character", "baz"], ["EndTag", "xmp"]], +"errors":[ + { "code": "abrupt-closing-of-empty-comment", "line": 1, "col": 19 } +]}, + +{"description":"Commented entities in RCDATA", +"initialStates":["RCDATA state"], +"lastStartTag":"xmp", +"input":" & <!-- & --> & </xmp>", +"output":[["Character", " & <!-- & --> & "], ["EndTag", "xmp"]]}, + +{"description":"Incorrect comment ending sequences in RCDATA or RAWTEXT", +"initialStates":["RCDATA state", "RAWTEXT state"], +"lastStartTag":"xmp", +"input":"foo<!-- x --x>x-- >x--!>x--<></xmp>", +"output":[["Character", "foo<!-- x --x>x-- >x--!>x--<>"], ["EndTag", "xmp"]]} + +]} |