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

Unified Diff: third_party/WebKit/LayoutTests/inspector/components/geometry.html

Issue 1975723003: DevTools: fix janky transition in sensors panel (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: updated test and rebase Created 4 years, 7 months 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/inspector/components/geometry-expected.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: third_party/WebKit/LayoutTests/inspector/components/geometry.html
diff --git a/third_party/WebKit/LayoutTests/inspector/components/geometry.html b/third_party/WebKit/LayoutTests/inspector/components/geometry.html
index 497d954f4a1ae040c130e9041107e80048ef5583..9d7131ea78d95fd1b4d03063167df09eb7d58106 100644
--- a/third_party/WebKit/LayoutTests/inspector/components/geometry.html
+++ b/third_party/WebKit/LayoutTests/inspector/components/geometry.html
@@ -104,11 +104,20 @@ function test()
next();
},
- function testRadToDeg(next)
+ function testRadiansToDegrees(next)
{
var angles = [Math.PI, Math.PI / 4, Math.PI / 6];
for (var i = 0; i < angles.length; ++i)
- InspectorTest.addResult(String.sprintf("deg: %.4f", WebInspector.Geometry.radToDeg(angles[i])));
+ InspectorTest.addResult(String.sprintf("deg: %.4f", WebInspector.Geometry.radiansToDegrees(angles[i])));
+
+ next();
+ },
+
+ function testDegreesToRadians(next)
+ {
+ var angles = [-30, 0, 30, 90, 180];
+ for (var i = 0; i < angles.length; ++i)
+ InspectorTest.addResult(String.sprintf("rad: %.4f", WebInspector.Geometry.degreesToRadians(angles[i])));
next();
},
@@ -128,6 +137,25 @@ function test()
InspectorTest.addResult(String.sprintf("Euler angles: %.4f %.4f %.4f", angles.alpha, angles.beta, angles.gamma));
}
next();
+ },
+
+ function testEulerAnglesToRotate3DString(next)
+ {
+ var angles = [
+ new WebInspector.Geometry.EulerAngles(0, 0, 0),
+ new WebInspector.Geometry.EulerAngles(1, 2, 3),
+ new WebInspector.Geometry.EulerAngles(-1, -2, 3),
+ new WebInspector.Geometry.EulerAngles(-1, 2, -3),
+ new WebInspector.Geometry.EulerAngles(0, 1, 2),
+ new WebInspector.Geometry.EulerAngles(1, 0, 2),
+ new WebInspector.Geometry.EulerAngles(1, 2, 0)
+ ];
+
+ for (var i = 0; i < angles.length; ++i) {
+ var rotate3DString = angles[i].toRotate3DString();
+ InspectorTest.addResult(String.sprintf("Transform: %s", rotate3DString));
+ }
+ next();
}
]);
« no previous file with comments | « no previous file | third_party/WebKit/LayoutTests/inspector/components/geometry-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698