Package net.sourceforge.marathon.component

Examples of net.sourceforge.marathon.component.MButton


            throw new RuntimeException("tried to add already existing component to TestDialog");
        }
    }

    public MButton getMButton() {
        return new MButton(button, button.getName(), null, WindowMonitor.getInstance());
    }
View Full Code Here


    public void tearDown() throws Exception {
    }

    @Test
    public void testRecordWindowTagOnClick() {
        MButton button = getMButton("dialog1", "button1");
        recorder.record(click(button, 1));
        recorder.record(click(button, 2));
        AWTSync.sync();
        assertScriptEquals(i1 + "if window('dialog1'):\n" + i2 + "click('button1')\n" + i2 + "doubleclick('button1')\n" + i1
                + "close()\n");
View Full Code Here

        };
    }

    @Test
    public void testRecordWindowTagOnSelect() {
        MButton button = new MButton(new JButton("text"), "button1", null, WindowMonitor.getInstance());
        WindowId windowId = new WindowIdMock("dialog1");
        button.setWindowId(windowId);
        recorder.record(new MockRecordedSelect(button.getComponentId(), windowId, "text"));
        AWTSync.sync();
        assertScriptEquals(i1 + "if window('dialog1'):\n" + i2 + "select('button1', 'text')\n" + i1 + "close()\n");
    }
View Full Code Here

    private void assertScriptEquals(String script) {
        assertEquals(script, listener.script);
    }

    private MButton getMButton(String dialogTitle, String name) {
        MButton button = new MButton(null, name, null, WindowMonitor.getInstance());
        button.setWindowId(new WindowIdMock(dialogTitle));
        return button;
    }
View Full Code Here

TOP

Related Classes of net.sourceforge.marathon.component.MButton

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.