////////////////////////////////////////////////////////////////////////////
/**
* Test for {@link DockLayoutPanelInfo#getSize(WidgetInfo)}.
*/
public void test_getSize() throws Exception {
DockLayoutPanelInfo panel =
parseJavaInfo(
"public class Test extends DockLayoutPanel {",
" public Test() {",
" super(Unit.MM);",
" {",
" Button button_1 = new Button();",
" addWest(button_1, 1.0);",
" }",
" {",
" Button button_2 = new Button();",
" addNorth(button_2, 2.0);",
" }",
" {",
" Button button_3 = new Button();",
" addEast(button_3, 3.0);",
" }",
" {",
" Button button_4 = new Button();",
" addSouth(button_4, 4.0);",
" }",
" {",
" Button button_5 = new Button();",
" add(button_5);",
" }",
" }",
"}");
panel.refresh();
{
WidgetInfo button_1 = getJavaInfoByName("button_1");
assertEquals(1.0, getSize(button_1), 0.001);
}
{