Summary: | [GTK] W3C CSS2.1 anonymous table tests are failing | ||||||
---|---|---|---|---|---|---|---|
Product: | WebKit | Reporter: | Michael Catanzaro <mcatanzaro> | ||||
Component: | WebKitGTK | Assignee: | Michael Catanzaro <mcatanzaro> | ||||
Status: | RESOLVED FIXED | ||||||
Severity: | Normal | CC: | bugs-noreply, bugzilla, clopez, commit-queue, mario, mcatanzaro, zalan | ||||
Priority: | P2 | ||||||
Version: | Other | ||||||
Hardware: | PC | ||||||
OS: | Linux | ||||||
Attachments: |
|
Description
Michael Catanzaro
2015-12-18 18:04:30 PST
I fixed the tests locally by simply renaming the file extension, e.g. by renaming table-anonymous-objects-015.xht to table-anonymous-objects-015.xhtml. This also causes shared-mime-info detects the content type as application/xhtml+xml instead of text/html. Bastien, I'm CCing you since this might be a shared-mime-info bug. I found in freedesktop.org.xml.in: <mime-type type="application/xhtml+xml"> <_comment>XHTML page</_comment> <acronym>XHTML</acronym> <expanded-acronym>Extensible HyperText Markup Language</expanded-acronym> <sub-class-of type="application/xml"/> <generic-icon name="text-html"/> <glob pattern="*.xhtml"/> <root-XML namespaceURI='http://www.w3.org/1999/xhtml' localName='html'/> </mime-type> Maybe the simple fix is to add: <glob pattern="*.xht"/> ? But maybe that would just be a workaround, not sure. As I mentioned in the mailing list [1], I think shared-mime-info could be the right place to change this, so that WebKit will do the right thing according to the MIME types registered in WebCore/platform/MIMETypeRegistry.cpp. That said, I'm not sure of what other implications doing that change in shared-mime-info could have, so better see what Bastien has to say about it before assuming that's the right thing to do instead of, say, hacking it somehow in WebKit itself (if that's even possible). [1]https://lists.webkit.org/pipermail/webkit-gtk/2016-January/002501.html I've added *.xht as a suffix for XHTML files in shared-mime-info, but, really, relying on something as coarse as the mime-type from shared-mime-info seems bizarre. I mean, you have a parser that surely can see the difference between HTML, XHTML and whatever other variants, and a big one at that. If you need something more from shared-mime-info, please file a bug with a patch following the HACKING file in the shared-mime-info git repo. Created attachment 268664 [details]
Patch
(In reply to comment #3) > If you need something more from shared-mime-info, please file a bug with a > patch following the HACKING file in the shared-mime-info git repo. Your patches work great, nothing else needed. Thanks! Comment on attachment 268664 [details]
Patch
LGTM
Comment on attachment 268664 [details] Patch Clearing flags on attachment: 268664 Committed r194845: <http://trac.webkit.org/changeset/194845> All reviewed patches have been landed. Closing bug. |