Hello all, I have begun using Canoo Webtest to define some Unit tests for a web application that uses the SmartClient framework.
After some trial and error, it appears that the only "good" way to programmatically click a button for a SmartClient application is to: 1. Know the button's ID for SmartClient (for example, foo) 2. Call "foo.click()" in JavaScript, in the page's context. I would like to be able to click a button this way through as simple a series of steps as possible, in Groovy. So, it boils down to: * How can I, from a webtest written in Groovy, get a reference to the instance of com.gargoylesoftware.htmlunit.WebClient in use? * How can I tell WebClient to run a given String as JavaScript? I realize that these questions are not very hard, however: * Though I am quite familiar with Java, the writing of these tests is my very first try at Groovy; and, as I have not been able to find a source file for the com/canoo/webtest/WebtestCase.class from which my tests inherit, I do not quite know where or how to search for the relevant information. * I already have a lead for the second question with the WebClient.getJavaScriptEngine() method, but I would like to know if anyone would know of a "cleaner", better documented way. Thank you in advance for your help, -- Jean Hominal _______________________________________________ WebTest mailing list WebTest@lists.canoo.com http://lists.canoo.com/mailman/listinfo/webtest