| Index: third_party/WebKit/LayoutTests/typedcssom/scaleTransformComponent.html
|
| diff --git a/third_party/WebKit/LayoutTests/typedcssom/scaleTransformComponent.html b/third_party/WebKit/LayoutTests/typedcssom/scaleTransformComponent.html
|
| deleted file mode 100644
|
| index 29e332354b461e898dc9e6b222079fb8f7a400dd..0000000000000000000000000000000000000000
|
| --- a/third_party/WebKit/LayoutTests/typedcssom/scaleTransformComponent.html
|
| +++ /dev/null
|
| @@ -1,94 +0,0 @@
|
| -<!DOCTYPE html>
|
| -<script src="../resources/testharness.js"></script>
|
| -<script src="../resources/testharnessreport.js"></script>
|
| -
|
| -<script>
|
| -var EPSILON = 1e-6; // float epsilon
|
| -var values = [
|
| - {input: new Scale(0, 0), x: 0, y: 0, z: 1, is2DComponent: true,
|
| - cssString: "scale(0, 0)"},
|
| - {input: new Scale(1, 2), x: 1, y: 2, z: 1, is2DComponent: true,
|
| - cssString: "scale(1, 2)"},
|
| - {input: new Scale(-2, -4), x: -2, y: -4, z: 1, is2DComponent: true,
|
| - cssString: "scale(-2, -4)"},
|
| - {input: new Scale(3.4, 2.7), x: 3.4, y: 2.7, z: 1, is2DComponent: true,
|
| - cssString: "scale(3.4, 2.7)"},
|
| - {input: new Scale(0, 0, 0), x: 0, y: 0, z: 0, is2DComponent: false,
|
| - cssString: "scale3d(0, 0, 0)"},
|
| - {input: new Scale(1, 2, 3), x: 1, y: 2, z: 3, is2DComponent: false,
|
| - cssString: "scale3d(1, 2, 3)"},
|
| - {input: new Scale(3.5, -2.7, -2), x: 3.5, y: -2.7, z: -2, is2DComponent: false,
|
| - cssString: "scale3d(3.5, -2.7, -2)"}
|
| -];
|
| -
|
| -test(function() {
|
| - for (var i = 0; i < values.length; ++i) {
|
| - assert_equals(values[i].input.x, values[i].x);
|
| - assert_equals(values[i].input.y, values[i].y);
|
| - assert_equals(values[i].input.z, values[i].z);
|
| - }
|
| -}, "Test that the (x, y, z) values for Scale are correct.");
|
| -
|
| -test(function() {
|
| - for (var i = 0; i < values.length; ++i) {
|
| - assert_equals(values[i].input.is2DComponent(), values[i].is2DComponent);
|
| - }
|
| -}, "Test that the is2DComponent values for Scale is correct.");
|
| -
|
| -test(function() {
|
| - for (var i = 0; i < values.length; ++i) {
|
| - assert_equals(values[i].input.cssString, values[i].cssString);
|
| - }
|
| -}, "Test that the cssString for Scale is correct.");
|
| -
|
| -test(function() {
|
| - assert_throws(null, () => { new Scale(); });
|
| - assert_throws(null, () => { new Scale(1); });
|
| -}, "Test that invalid number of arguments for Scale throws an exception.");
|
| -
|
| -test(function() {
|
| - assert_throws(null, () => { new Scale(NaN, 0); });
|
| - assert_throws(null, () => { new Scale(0, NaN); });
|
| - assert_throws(null, () => { new Scale(NaN, NaN); });
|
| - assert_throws(null, () => { new Scale(Infinity, 0); });
|
| - assert_throws(null, () => { new Scale(-Infinity, 0); });
|
| - assert_throws(null, () => { new Scale("hello", 0); });
|
| - assert_throws(null, () => { new Scale(0, "world"); });
|
| - assert_throws(null, () => { new Scale(undefined, 0); });
|
| - assert_throws(null, () => { new Scale({}, {}); });
|
| -
|
| - assert_throws(null, () => { new Scale("hello", 0, 0); });
|
| - assert_throws(null, () => { new Scale(0, NaN, 0); });
|
| - assert_throws(null, () => { new Scale(0, Infinity, 0); });
|
| - assert_throws(null, () => { new Scale(0, 0, NaN); });
|
| - assert_throws(null, () => { new Scale(0, 0, Infinity); });
|
| - assert_throws(null, () => { new Scale(0, 0, -Infinity); });
|
| - assert_throws(null, () => { new Scale(0, 0, undefined); });
|
| - assert_throws(null, () => { new Scale(undefined, undefined, 0); });
|
| - assert_throws(null, () => { new Scale(NaN, undefined, 0); });
|
| - assert_throws(null, () => { new Scale(NaN, 0, NaN); });
|
| - assert_throws(null, () => { new Scale(0, "hello", "world"); });
|
| - assert_throws(null, () => { new Scale(0, {}, {}); });
|
| - assert_throws(null, () => { new Scale({}, {}, {}); });
|
| - assert_throws(null, () => { new Scale(NaN, NaN, NaN); });
|
| -}, "Test that invalid input throws an exception.");
|
| -
|
| -test(function() {
|
| - for (var i = 0; i < values.length; ++i) {
|
| - var input = values[i].input;
|
| - var inputAsMatrix = input.asMatrix();
|
| - assert_equals(inputAsMatrix.is2DComponent(), input.is2DComponent());
|
| -
|
| - var expectedMatrix = input.is2DComponent() ? new Matrix(input.x, 0, 0, input.y, 0, 0) :
|
| - new Matrix(input.x, 0, 0, 0, 0, input.y, 0, 0, 0, 0, input.z, 0, 0, 0, 0, 1);
|
| - for (var attribute in expectedMatrix) {
|
| - if (typeof expectedMatrix[attribute] === "number") {
|
| - assert_approx_equals(inputAsMatrix[attribute], expectedMatrix[attribute], EPSILON);
|
| - } else {
|
| - assert_equals(inputAsMatrix[attribute], expectedMatrix[attribute]);
|
| - }
|
| - }
|
| - }
|
| -}, "Test that asMatrix is constructed correctly for Scale.");
|
| -
|
| -</script>
|
|
|