Index: sky/tests/raw/render_box.dart |
diff --git a/sky/tests/raw/render_box.dart b/sky/tests/raw/render_box.dart |
index bb15c80516239c0e9d2312473e31f86b7020d730..82a79783c9ed9873a83138897cc73cfe10b1129f 100644 |
--- a/sky/tests/raw/render_box.dart |
+++ b/sky/tests/raw/render_box.dart |
@@ -7,27 +7,12 @@ import '../resources/unit.dart'; |
import 'dart:sky' as sky; |
import 'package:sky/framework/layout2.dart'; |
-class RenderSizedBox extends RenderBox { |
- final sky.Size desiredSize; |
- |
- RenderSizedBox({ this.desiredSize }); |
- |
- BoxDimensions getIntrinsicDimensions(BoxConstraints constraints) { |
- return new BoxDimensions.withConstraints(constraints, |
- width: desiredSize.width, |
- height: desiredSize.height); |
- } |
- |
- void performLayout() { |
- size = constraints.constrain(desiredSize); |
- } |
-} |
- |
void main() { |
initUnit(); |
test("should size to render view", () { |
- RenderSizedBox root = new RenderSizedBox(desiredSize: new sky.Size.infinite()); |
+ RenderSizedBox root = new RenderSizedBox( |
+ new RenderDecoratedBox(new BoxDecoration(backgroundColor: 0xFF00FF00))); |
RenderView renderView = new RenderView(child: root); |
renderView.layout(new ViewConstraints(width: sky.view.width, height: sky.view.height)); |
expect(root.size.width, equals(sky.view.width)); |