Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / http / tests / webfont / fontfaceset-status-attribute.html
blob7f9d95aafc84deb2ea83cfb67fb5e96bdfd6f3fd
1 <html>
2 <head>
3 <script src="../../js-test-resources/js-test.js"></script>
4 <style>
5 @font-face {
6 font-family: 'TestFont';
7 src: url(slow-ahem-loading.cgi);
9 </style>
10 <script>
11 description('Test for FontFaceSet.status attribute');
13 window.jsTestIsAsync = true;
15 function runTests() {
16 shouldBeFalse("document.fonts.check('10px TestFont')");
17 shouldBeEqualToString("document.fonts.status", "loaded");
18 document.fonts.load('10px TestFont').then(onsuccess);
19 shouldBeEqualToString("document.fonts.status", "loading");
22 function onsuccess() {
23 shouldBeTrue("document.fonts.check('10px TestFont')");
24 document.fonts.ready.then(onFontsReady);
27 function onFontsReady() {
28 shouldBeEqualToString("document.fonts.status", "loaded");
29 finishJSTest();
32 if (document.fonts)
33 runTests();
34 else {
35 testFailed('document.fonts does not exist');
36 finishJSTest();
38 </script>
39 </head>
40 <body>
41 </body>
42 </html>