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

Unified Diff: tests/dom/css_test.dart

Issue 10178014: Copy lib/dom tests that use dart:html to lib/html. (Closed) Base URL: https://dart.googlecode.com/svn/branches/bleeding_edge/dart
Patch Set: . Created 8 years, 8 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 | « tests/dom/cross_frame_test.dart ('k') | tests/dom/document_test.dart » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tests/dom/css_test.dart
diff --git a/tests/dom/css_test.dart b/tests/dom/css_test.dart
deleted file mode 100644
index 2e4f9165eb035b20e9bb51aa9d466b22dccfaadd..0000000000000000000000000000000000000000
--- a/tests/dom/css_test.dart
+++ /dev/null
@@ -1,43 +0,0 @@
-#library('CSSTest');
-#import('../../lib/unittest/unittest.dart');
-#import('../../lib/unittest/html_config.dart');
-#import('dart:html');
-
-main() {
- useHtmlConfiguration();
- test('CSSMatrix', () {
- CSSMatrix matrix1 = new CSSMatrix();
- Expect.equals(1, matrix1.m11.round());
- Expect.equals(0, matrix1.m12.round());
-
- CSSMatrix matrix2 = new CSSMatrix('matrix(1, 0, 0, 1, -835, 0)');
- Expect.equals(1, matrix2.a.round());
- Expect.equals(-835, matrix2.e.round());
- });
- test('Point', () {
- Element element = new Element.tag('div');
- element.attributes['style'] =
- '''
- position: absolute;
- width: 60px;
- height: 100px;
- left: 0px;
- top: 0px;
- background-color: red;
- -webkit-transform: translate3d(250px, 100px, 0px) perspective(500px) rotateX(30deg);
- ''';
- document.body.nodes.add(element);
-
- Point point = new Point(5, 2);
- checkPoint(5, 2, point);
- checkPoint(256, 110, window.webkitConvertPointFromNodeToPage(element, point));
- point.y = 100;
- checkPoint(5, 100, point);
- checkPoint(254, 196, window.webkitConvertPointFromNodeToPage(element, point));
- });
-}
-
-void checkPoint(expectedX, expectedY, Point point) {
- Expect.equals(expectedX, point.x.round(), 'Wrong point.x');
- Expect.equals(expectedY, point.y.round(), 'Wrong point.y');
-}
« no previous file with comments | « tests/dom/cross_frame_test.dart ('k') | tests/dom/document_test.dart » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698