Index: third_party/WebKit/LayoutTests/fast/table/table-cell-scope-getter.html |
diff --git a/third_party/WebKit/LayoutTests/fast/table/table-cell-scope-getter.html b/third_party/WebKit/LayoutTests/fast/table/table-cell-scope-getter.html |
new file mode 100644 |
index 0000000000000000000000000000000000000000..4e62535e7c6046da42374b72614d5ac0bbdaceeb |
--- /dev/null |
+++ b/third_party/WebKit/LayoutTests/fast/table/table-cell-scope-getter.html |
@@ -0,0 +1,83 @@ |
+<!DOCTYPE html> |
+<head> |
+<script src="../../resources/testharness.js"></script> |
+<script src="../../resources/testharnessreport.js"></script> |
+</head> |
+<body> |
+ <script> |
+ td = document.createElement('td'); |
tkent
2016/09/29 23:15:56
indentation looks bad.
|
+test(function() { |
+ assert_equals(td.scope, ''); |
+ td.scope = "Foo"; |
+ assert_equals(td.scope, ''); |
+ td.setAttribute("scope", ""); |
+ assert_equals(td.scope, ''); |
+ td.setAttribute("scope", "Foo"); |
+ assert_equals(td.scope, ''); |
+}, '"Default value of scope getter is empty string"'); |
+ |
+test(function() { |
+ td.scope = "row"; |
+ assert_equals(td.scope, 'row'); |
+ td.scope = "ROW"; |
+ assert_equals(td.scope, 'row'); |
+ td.scope = "Row"; |
+ assert_equals(td.scope, 'row'); |
+ |
+ td.setAttribute("scope", "row"); |
+ assert_equals(td.scope, 'row'); |
+ td.setAttribute("scope", "ROW"); |
+ assert_equals(td.scope, 'row'); |
+ td.setAttribute("scope", "Row"); |
+ assert_equals(td.scope, 'row'); |
+}, 'Row value is accepted with case-sensivity'); |
+ |
+test(function() { |
+ td.scope = "col"; |
+ assert_equals(td.scope, 'col'); |
+ td.scope = "COL"; |
+ assert_equals(td.scope, 'col'); |
+ td.scope = "Col"; |
+ assert_equals(td.scope, 'col'); |
+ |
+ td.setAttribute("scope", "col"); |
+ assert_equals(td.scope, 'col'); |
+ td.setAttribute("scope", "COL"); |
+ assert_equals(td.scope, 'col'); |
+ td.setAttribute("scope", "Col"); |
+ assert_equals(td.scope, 'col'); |
+}, 'Col value is accepted with case-sensivity'); |
+ |
+test(function() { |
+ td.scope = "rowgroup"; |
+ assert_equals(td.scope, 'rowgroup'); |
+ td.scope = "ROWGROUP"; |
+ assert_equals(td.scope, 'rowgroup'); |
+ td.scope = "Rowgroup"; |
+ assert_equals(td.scope, 'rowgroup'); |
+ |
+ td.setAttribute("scope", "rowgroup"); |
+ assert_equals(td.scope, 'rowgroup'); |
+ td.setAttribute("scope", "ROWGROUP"); |
+ assert_equals(td.scope, 'rowgroup'); |
+ td.setAttribute("scope", "Rowgroup"); |
+ assert_equals(td.scope, 'rowgroup'); |
+}, 'Rowgroup value is accepted with case-sensivity'); |
+ |
+test(function() { |
+ td.scope = "colgroup"; |
+ assert_equals(td.scope, 'colgroup'); |
+ td.scope = "COLGROUP"; |
+ assert_equals(td.scope, 'colgroup'); |
+ td.scope = "Colgroup"; |
+ assert_equals(td.scope, 'colgroup'); |
+ |
+ td.setAttribute("scope", "colgroup"); |
+ assert_equals(td.scope, 'colgroup'); |
+ td.setAttribute("scope", "COLGROUP"); |
+ assert_equals(td.scope, 'colgroup'); |
+ td.setAttribute("scope", "Colgroup"); |
+ assert_equals(td.scope, 'colgroup'); |
+}, 'Colgroup value is accepted with case-sensivity'); |
+ </script> |
+</body> |