Move parseFontFaceDescriptor to CSSPropertyParser.cpp
[chromium-blink-merge.git] / third_party / WebKit / LayoutTests / css3 / font-weight.html
blob6c83be881241fa40d92131aa7c43e1cdc0dae8d1
1 <html>
2 <head>
3 <style>
4 #bolder { font-weight: bolder; }
5 #lighter { font-weight: lighter; }
6 </style>
7 <script src="../resources/js-test.js"></script>
8 </head>
9 <body>
10 <div id="outer">
11 <div id="bolder"></div>
12 <div id="lighter"></div>
13 </div>
14 <div id="console"></div>
15 <script>
16 description('Test that font-weight: bolder and font-weight: lighter behave according to spec.');
18 table = [
19 ["100" , "100" , "normal", "100"],
20 ["200" , "200" , "normal", "100"],
21 ["300" , "300" , "normal", "100"],
22 ["400" , "normal", "bold" , "100"],
23 ["normal", "normal", "bold" , "100"],
24 ["500" , "500" , "bold" , "100"],
25 ["600" , "600" , "900" , "normal"],
26 ["700" , "bold" , "900" , "normal"],
27 ["bold" , "bold" , "900" , "normal"],
28 ["800" , "800" , "900" , "bold"],
29 ["900" , "900" , "900" , "bold"],
32 var outer = document.getElementById("outer");
33 var bolder = document.getElementById("bolder");
34 var lighter = document.getElementById("lighter");
35 for(var i=0; i<table.length; i++) {
36 outer.style.fontWeight = table[i][0];
37 shouldBeEqualToString('getComputedStyle(outer).fontWeight', table[i][1]);
38 shouldBeEqualToString('getComputedStyle(bolder).fontWeight', table[i][2]);
39 shouldBeEqualToString('getComputedStyle(lighter).fontWeight', table[i][3]);
41 </script>
42 </body>
43 </html>