OLD | NEW |
---|---|
(Empty) | |
1 <!DOCTYPE html> | |
2 <head> | |
3 <script src="../../resources/testharness.js"></script> | |
4 <script src="../../resources/testharnessreport.js"></script> | |
5 </head> | |
6 <body> | |
7 <script> | |
8 td = document.createElement('td'); | |
tkent
2016/09/29 23:15:56
indentation looks bad.
| |
9 test(function() { | |
10 assert_equals(td.scope, ''); | |
11 td.scope = "Foo"; | |
12 assert_equals(td.scope, ''); | |
13 td.setAttribute("scope", ""); | |
14 assert_equals(td.scope, ''); | |
15 td.setAttribute("scope", "Foo"); | |
16 assert_equals(td.scope, ''); | |
17 }, '"Default value of scope getter is empty string"'); | |
18 | |
19 test(function() { | |
20 td.scope = "row"; | |
21 assert_equals(td.scope, 'row'); | |
22 td.scope = "ROW"; | |
23 assert_equals(td.scope, 'row'); | |
24 td.scope = "Row"; | |
25 assert_equals(td.scope, 'row'); | |
26 | |
27 td.setAttribute("scope", "row"); | |
28 assert_equals(td.scope, 'row'); | |
29 td.setAttribute("scope", "ROW"); | |
30 assert_equals(td.scope, 'row'); | |
31 td.setAttribute("scope", "Row"); | |
32 assert_equals(td.scope, 'row'); | |
33 }, 'Row value is accepted with case-sensivity'); | |
34 | |
35 test(function() { | |
36 td.scope = "col"; | |
37 assert_equals(td.scope, 'col'); | |
38 td.scope = "COL"; | |
39 assert_equals(td.scope, 'col'); | |
40 td.scope = "Col"; | |
41 assert_equals(td.scope, 'col'); | |
42 | |
43 td.setAttribute("scope", "col"); | |
44 assert_equals(td.scope, 'col'); | |
45 td.setAttribute("scope", "COL"); | |
46 assert_equals(td.scope, 'col'); | |
47 td.setAttribute("scope", "Col"); | |
48 assert_equals(td.scope, 'col'); | |
49 }, 'Col value is accepted with case-sensivity'); | |
50 | |
51 test(function() { | |
52 td.scope = "rowgroup"; | |
53 assert_equals(td.scope, 'rowgroup'); | |
54 td.scope = "ROWGROUP"; | |
55 assert_equals(td.scope, 'rowgroup'); | |
56 td.scope = "Rowgroup"; | |
57 assert_equals(td.scope, 'rowgroup'); | |
58 | |
59 td.setAttribute("scope", "rowgroup"); | |
60 assert_equals(td.scope, 'rowgroup'); | |
61 td.setAttribute("scope", "ROWGROUP"); | |
62 assert_equals(td.scope, 'rowgroup'); | |
63 td.setAttribute("scope", "Rowgroup"); | |
64 assert_equals(td.scope, 'rowgroup'); | |
65 }, 'Rowgroup value is accepted with case-sensivity'); | |
66 | |
67 test(function() { | |
68 td.scope = "colgroup"; | |
69 assert_equals(td.scope, 'colgroup'); | |
70 td.scope = "COLGROUP"; | |
71 assert_equals(td.scope, 'colgroup'); | |
72 td.scope = "Colgroup"; | |
73 assert_equals(td.scope, 'colgroup'); | |
74 | |
75 td.setAttribute("scope", "colgroup"); | |
76 assert_equals(td.scope, 'colgroup'); | |
77 td.setAttribute("scope", "COLGROUP"); | |
78 assert_equals(td.scope, 'colgroup'); | |
79 td.setAttribute("scope", "Colgroup"); | |
80 assert_equals(td.scope, 'colgroup'); | |
81 }, 'Colgroup value is accepted with case-sensivity'); | |
82 </script> | |
83 </body> | |
OLD | NEW |