Chromium Code Reviews| Index: third_party/WebKit/LayoutTests/external/wpt/css-font-display/font-display.html |
| diff --git a/third_party/WebKit/LayoutTests/http/tests/webfont/font-display.html b/third_party/WebKit/LayoutTests/external/wpt/css-font-display/font-display.html |
| similarity index 88% |
| rename from third_party/WebKit/LayoutTests/http/tests/webfont/font-display.html |
| rename to third_party/WebKit/LayoutTests/external/wpt/css-font-display/font-display.html |
| index ec19d7a86ef0c52ef1966b622bc97d8808bc31a6..cc422e694631bd53094c63ee079753ebd8ef3060 100644 |
| --- a/third_party/WebKit/LayoutTests/http/tests/webfont/font-display.html |
| +++ b/third_party/WebKit/LayoutTests/external/wpt/css-font-display/font-display.html |
| @@ -1,5 +1,7 @@ |
| <!DOCTYPE html> |
| +<html class="reftest-wait"> |
| <title>Test for font-display @font-face descriptor</title> |
| +<link rel="match" href="font-display-expected.html"> |
|
foolip
2017/05/29 15:35:20
Please name this font-display-ref.html instead, th
Kunihiko Sakamoto
2017/05/30 04:11:10
Done.
|
| <style> |
| .hidden { display: none; } |
| </style> |
| @@ -16,9 +18,6 @@ |
| </tr> |
| </table> |
| <script> |
| -if (window.testRunner) |
| - testRunner.waitUntilDone(); |
| - |
| var fontDisplayValues = ['auto', 'block', 'swap', 'fallback', 'optional']; |
| var configs = [{time: 0, delay: 1000}, |
| {time: 1000, delay: 0}, |
| @@ -29,9 +28,7 @@ var configs = [{time: 0, delay: 1000}, |
| {time: 5000, delay: 8000}]; |
| function makeFontFaceDeclaration(family, config, display) { |
| - var url = '/resources/Ahem.ttf'; |
| - if (config.delay > 0) |
| - url = 'slow-ahem-loading.cgi?delay=' + config.delay + '&t=' + config.time; |
| + url = 'resources/slow-ahem-loading.py?ms=' + config.delay + '&t=' + config.time; |
|
foolip
2017/05/29 15:35:20
The t parameter isn't read by slow-ahem-loading.py
Kunihiko Sakamoto
2017/05/30 04:11:10
|t| is a dummy parameter that makes sure every con
foolip
2017/05/30 11:35:29
Since it's not needed, can you remove it? It now v
Kunihiko Sakamoto
2017/05/31 04:53:50
OK, removed.
|
| return '@font-face { font-family: ' + family + '; src: url(' + url + '); font-display: ' + display + '; }'; |
| } |
| @@ -63,8 +60,7 @@ window.onload = function() { |
| if (config.time == 0) { |
| setTimeout((function(tr){ |
| tr.classList.remove('hidden'); |
| - if (window.testRunner) |
| - testRunner.notifyDone(); |
| + document.documentElement.classList.remove("reftest-wait"); |
| }).bind(null, tr), maxTime); |
| } else { |
| setTimeout((function(tr){tr.classList.remove('hidden')}).bind(null, tr), maxTime - config.time); |
| @@ -73,3 +69,4 @@ window.onload = function() { |
| } |
| </script> |
| +</html> |