I was mistaken... the option is a nested tag for option, so I need to include
it to the config part:
following works:
webtest("My first test") {
config {
option name: "ThrowExceptionOnScriptError",value: "false"
}
//further steps
....}
aldana wrote:
>
> I had a look at the test superclass and indeed there is no option() method
> available (in contrast to config() and webtest()).
>
> never the less following fails also (it does not know the option tag):
> def ant=createAntBuilder()
> ant.option(....)
>
> I hope I don't need to import the taskdef explicitly with length yucky ant
> lib loading code... Is there a reason why WebtestCase does not offer an
> option() method?
>
>
> aldana wrote:
>>
>> hi,
>>
>> I am playing around with webtest and first impressions are very good. but
>> several pages are making problems with JS-errors so I want to set
>> js-exception detection switched off (see
>> http://webtest.canoo.com/webtest/manual/option.html).
>>
>> I tried following but webtest gives me exception when while executing the
>> option step, what is the correct way to use the option step in groovy:
>>
>> class FirstWebTest extends WebtestCase {
>>
>> void testLogin() {
>> //fails
>> option name: "ThrowExceptionOnScriptError", value: "false"
>>
>> webtest("My first test") {
>> group(description: "login to xxx") {
>> //... test steps
>> }
>> }
>> }
>> }
>>
>> thanks
>>
>>
>
>
-----
manuel aldana
aldana((at))gmx.de
software-engineering blog: http://www.aldana-online.de
--
View this message in context:
http://www.nabble.com/using-option-step-in-groovy-syntax-tp24134316p24134464.html
Sent from the WebTest mailing list archive at Nabble.com.
_______________________________________________
WebTest mailing list
[email protected]
http://lists.canoo.com/mailman/listinfo/webtest