Steps to reproduce the problem: 1. Open https://jsfiddle.net/stx0k3dh/6/ 2. Observe the last but one property value - it doesn't match the input. All tests work fine in Firefox 51. Chrome 56 passes the test that WebKit fails but... fails the last one, i.e. turns single quotes into double ones (oh irony). I reported the Chrome issue at https://bugs.chromium.org/p/chromium/issues/detail?id=697663.
All browsers fail some of the tests (perhaps the standards have changed): Chrome: 1. Last line makes double quotes instead of single. Firefox: 1. Second line does not provide a leading space. But Safari fails many: 1. Second line does not provide a leading space. 2. Third line does not provide a trailing space. 3. Last line makes double quotes instead of single.
<rdar://problem/97084846>
Yes, the spec has changed, see https://github.com/w3c/csswg-drafts/issues/774 The value should now be trimmed.
I've noticed WPTs didn't account for this spec change so I submitted https://github.com/web-platform-tests/wpt/issues/34880