Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(1009)

Side by Side Diff: third_party/WebKit/LayoutTests/fast/dom/geometry-interfaces-dom-matrix-setMatrixValue.html

Issue 2478993002: [GeometryInterface] Remove Constructor(DOMMatrixReadOnly). (Closed)
Patch Set: rebase Created 4 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View unified diff | Download patch
OLDNEW
1 <!DOCTYPE HTML> 1 <!DOCTYPE HTML>
2 <script src="../../resources/testharness.js"></script> 2 <script src="../../resources/testharness.js"></script>
3 <script src="../../resources/testharnessreport.js"></script> 3 <script src="../../resources/testharnessreport.js"></script>
4 <script src="./resources/geometry-interfaces-test-helpers.js"></script> 4 <script src="./resources/geometry-interfaces-test-helpers.js"></script>
5 <script> 5 <script>
6 6
7 var matrix2d = new DOMMatrix([5, 4, 11, 34, 55, 11]); 7 var matrix2d = [5, 4, 11, 34, 55, 11];
8 var matrix3d = new DOMMatrix([5, 11, 55, 77, 44, 33, 55, 75, 88, 99, 12, 43, 65, 36, 85, 25]); 8 var matrix3d = [5, 11, 55, 77, 44, 33, 55, 75, 88, 99, 12, 43, 65, 36, 85, 25];
9 9
10 test(() => { 10 test(() => {
11 var actualMatrix1 = new DOMMatrix(matrix2d); 11 var actualMatrix1 = new DOMMatrix(matrix2d);
12 var actualMatrix2 = new DOMMatrix(matrix3d); 12 var actualMatrix2 = new DOMMatrix(matrix3d);
13 var expectedMatrix = new DOMMatrix(); 13 var expectedMatrix = new DOMMatrix();
14 actualMatrix1.setMatrixValue(""); 14 actualMatrix1.setMatrixValue("");
15 assert_true(actualMatrix1.is2D); 15 assert_true(actualMatrix1.is2D);
16 assert_matrix_almost_equals(actualMatrix1, expectedMatrix); 16 assert_matrix_almost_equals(actualMatrix1, expectedMatrix);
17 actualMatrix2.setMatrixValue(""); 17 actualMatrix2.setMatrixValue("");
18 assert_true(actualMatrix2.is2D); 18 assert_true(actualMatrix2.is2D);
(...skipping 265 matching lines...) Expand 10 before | Expand all | Expand 10 after
284 actualMatrix.setMatrixValue("translateX(calc(10px + 1em))"); 284 actualMatrix.setMatrixValue("translateX(calc(10px + 1em))");
285 }, "Can't parse without absolute unit."); 285 }, "Can't parse without absolute unit.");
286 286
287 //actualMatrix should be not changed. 287 //actualMatrix should be not changed.
288 assert_true(actualMatrix.is2D); 288 assert_true(actualMatrix.is2D);
289 assert_matrix_almost_equals(actualMatrix, expectedMatrix); 289 assert_matrix_almost_equals(actualMatrix, expectedMatrix);
290 290
291 }, "DOMMatrix.setMatrix(): Exception test."); 291 }, "DOMMatrix.setMatrix(): Exception test.");
292 292
293 </script> 293 </script>
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698