Bug 207736 - import-w3c-tests rewriter breaks tests imported/w3c/web-platform-tests/encoding/legacy-mb-japanese/iso-2022-jp/iso2022jp-decode*
Summary: import-w3c-tests rewriter breaks tests imported/w3c/web-platform-tests/encodi...
Status: NEW
Alias: None
Product: WebKit
Classification: Unclassified
Component: Tools / Tests (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Nobody
URL:
Keywords: InRadar
Depends on:
Blocks: 207734 246222
  Show dependency treegraph
 
Reported: 2020-02-13 18:27 PST by Carlos Alberto Lopez Perez
Modified: 2024-01-29 02:48 PST (History)
2 users (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Carlos Alberto Lopez Perez 2020-02-13 18:27:18 PST
This was discovered meanwhile updating the encoding/ checkout in bug 207644

- The WPT test importer does some strange rewrites of the following two files
imported/w3c/web-platform-tests/encoding/legacy-mb-japanese/iso-2022-jp/iso2022jp_chars-csiso2022jp.html (diff from wpt original file: http://sprunge.us/sEkd3Z?diff )
imported/w3c/web-platform-tests/encoding/legacy-mb-japanese/iso-2022-jp/iso2022jp_chars.html (diff from wpt original file: http://sprunge.us/XYoSO1?diff )

As you see it adds some strange extra ";" and also comments out some closing span tags.

This two files are needed by the tests 
imported/w3c/web-platform-tests/encoding/legacy-mb-japanese/iso-2022-jp/iso2022jp-decode.html
imported/w3c/web-platform-tests/encoding/legacy-mb-japanese/iso-2022-jp/iso2022jp-decode-csiso2022jp.html

this two tests load those files inside an iframe

This strange rewrite that the WPT importer does breaks the subtests affected by those lines
If the right file its used (the original from WPT) all subtests pass (zero failures), but with the strange file rewrote by the WPT test importer there are 26 FAIL lines on the expectation that shouldn't be there.
Comment 1 Radar WebKit Bug Importer 2020-09-21 15:36:04 PDT
<rdar://problem/69331956>
Comment 2 Sam Sneddon [:gsnedders] 2020-11-16 11:04:43 PST
I'd assume this is caused by the webkitpy.w3c.test_converter parse/serialize cycle. 

One option is waiting on bug 218987 and hoping we get rid of the test converter at that point (or waiting for part 2, bug 218992, which will be the latest point at which it is gone).

The other option is getting the test_converter to not actually rewrite the file if it doesn't make any mutations.