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

Unified Diff: sky/tests/raw/render_box.dart

Issue 1177043008: Make it possible to test that the stock app doesn't crash on startup and paints the basic scaffold … (Closed) Base URL: https://github.com/domokit/mojo.git@master
Patch Set: Created 5 years, 6 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 | « sky/tests/raw/padding_deflate-expected.txt ('k') | sky/tests/raw/render_box-expected.txt » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: sky/tests/raw/render_box.dart
diff --git a/sky/tests/raw/render_box.dart b/sky/tests/raw/render_box.dart
index 25ff3bb8d799fad6a6efa100d28201174cf65c49..e322213d566c73c102f2830edee963c5ea1a2023 100644
--- a/sky/tests/raw/render_box.dart
+++ b/sky/tests/raw/render_box.dart
@@ -2,13 +2,15 @@
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
-import '../resources/third_party/unittest/unittest.dart';
-import '../resources/unit.dart';
-import '../resources/display_list.dart';
import 'dart:sky' as sky;
+
import 'package:sky/framework/rendering/box.dart';
import 'package:sky/framework/rendering/object.dart';
+import '../resources/display_list.dart';
+import '../resources/third_party/unittest/unittest.dart';
+import '../resources/unit.dart';
+
void main() {
initUnit();
@@ -18,14 +20,8 @@ void main() {
decoration: new BoxDecoration(backgroundColor: const sky.Color(0xFF00FF00))
)
);
- TestView renderView = new TestView(child: root);
- renderView.attach();
- renderView.rootConstraints = new ViewConstraints(width: sky.view.width, height: sky.view.height);
- renderView.scheduleInitialLayout();
- RenderObject.flushLayout();
+ new TestRenderView(root);
expect(root.size.width, equals(sky.view.width));
expect(root.size.height, equals(sky.view.height));
- renderView.paintFrame();
- print(renderView.lastPaint); // TODO(ianh): figure out how to make this fit the unit testing framework better
});
}
« no previous file with comments | « sky/tests/raw/padding_deflate-expected.txt ('k') | sky/tests/raw/render_box-expected.txt » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698