WebKit Bugzilla
New
Browse
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
ASSIGNED
Bug 203789
Copying reference files in import-w3c-tests breaks when ref files contain references to support files
https://bugs.webkit.org/show_bug.cgi?id=203789
Summary
Copying reference files in import-w3c-tests breaks when ref files contain ref...
Simon Fraser (smfr)
Reported
2019-11-02 12:32:17 PDT
In css/css-backgrounds, background-image-003.html has a reference of reference/background-image-001-ref.html. We copy reference/background-image-001-ref.html to background-image-003-expected.html, but it has an image resource with a relative URL, and since the copy moved it to a different directory, that relative URL is now broken. We have to fix
bug 203784
and stop copying to -expected.html
Attachments
Add attachment
proposed patch, testcase, etc.
Carlos Alberto Lopez Perez
Comment 1
2020-01-27 11:59:37 PST
The WPT test importer detects this and does a rewrite of the relative URL when importing the ref-test. The tag '<img class="green" src="../support/green.png">' should get updated to '<img class="green" src="support/green.png">' on the generated -expected.html. Maybe it didn't work for you because the script doesn't do this rewrite if you import from a local source directory. Example, if you do: Tools/Scripts/import-w3c-tests -v -s /home/user/local-wpt-checkout css/css-backgrounds -d /home/user/WebKit/LayoutTests/imported/w3c/web-platform-tests Then it don't do any rewrite But if you do if you run it like: Tools/Scripts/import-w3c-tests -t web-platform-tests/css/css-background Then it will do the rewrites. TIP: pass also the flag "-v" so you can see if it does the rewrites and if there is any WARNING doing that. The logic it uses for that seems to be here:
https://trac.webkit.org/browser/webkit/trunk/Tools/Scripts/webkitpy/w3c/test_importer.py?rev=255074#L467
It does a rewrite of the URLs pointed by url(), href= or src= inside <style> tags as well as inside this list of tags:
https://trac.webkit.org/browser/webkit/trunk/Tools/Scripts/webkitpy/w3c/test_converter.py?rev=255074#L222
In any case I also think we should fix
bug 203784
and stop doing rewrites.
Radar WebKit Bug Importer
Comment 2
2020-09-21 15:39:09 PDT
<
rdar://problem/69332145
>
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug