Hi Guyz,
public class TestSeleniumV2 implements EntryPoint {
public void onModuleLoad() {
Button b1 = new Button("click ME!");
b1.setID("teto");
final Label l1 = new Label("labelTest");
l1.setLeft(100);
b1.addClickHandler( new ClickHandler() {
@Override
public void onClick(ClickEvent event) {
System.out.println("Button is Clicked");
Window.alert("test");
l1.setContents("Modifyed");
}
});
l1.draw();
b1.draw();
}
}
Test Class:
HttpCommandProcessor processor = new HttpCommandProcessor("localhost",
4444,
"*firefox",
"http://127.0.0.1:8888/TestSeleniumV2.html?gwt.codesvr=127.0.0.1:9997");
selenium = new DefaultSelenium(
processor);
selenium.start();
selenium.open("http://127.0.0.1:8888/TestSeleniumV2.html?gwt.codesvr=127.0.0.1:9997");
selenium.waitForPageToLoad("20000");
//selenium.clickAndWait("scLocator=//Button[ID=\"teto\"]");
// selenium.waitForCondition("selenium.browserbot.getCurrentWindow().document.getElementById('teto')", "400");
selenium.click("scLocator=//Button[ID=\"teto\"]");
My Question is why when i execute the above code the Window.alert() Does not execute in spite of the syso and changing the label content are executed?