Hi
   I tried putting the grooy """  and """ around the def and print . But I
get a different error now that says "x is not defined . Will take a detailed
look.

   Thanks Marc for the response . This explains why I see the print's much
before the execution os the tests :-)

Regards
Hari

On Fri, May 16, 2008 at 3:39 PM, Pfau, Matthias <[EMAIL PROTECTED]> wrote:

> Sorry Marc!
> I did not notice that you already answered Harihara Vinayakaram's
> question, which is indeed about the same problem...
>
> Thanks!
>
> Kind Regards
> Matthias
>
> -----Original Message-----
> From: [EMAIL PROTECTED]
> [mailto:[EMAIL PROTECTED] On Behalf Of Pfau, Matthias
> Sent: Freitag, 16. Mai 2008 11:35
> To: [email protected]
> Subject: [Webtest] Interaction between Groovy and Webtest
>
> Hi,
> I am currently trying to do something like the following:
> 1. Extract data from an XLS-Sheet (e.g. a List of Dates like
> "12.05.2008")
> 2. Fill a form and submit
> 3. Check that the date gets displayed correctly as part of the response
>
> The problem is, that the response's date is formatted in another way
> (e.g. it simply prints out the year: "2008").
>
> I tried to use groovy to modify the String but I did not manage to get
> the String out of ant. So the real question here is how to get the
> property out of ant in a Builder. The following demonstrates the
> problem:
>
> ant.webtest(name:"PropertyTest"){
>    steps {
>            storeProperty(description:"setting dateTest",
> name:"dateTest",value:'18.05.2005',
>                        propertyType:"ant")
>
>                assert ant.project.properties.dateTest == null
>            assert ant.project.properties.'dateTest' == null
>    }
> }
> assert ant.project.properties.dateTest == '18.05.2005'
> assert ant.project.properties.'dateTest' == '18.05.2005'
>
>
> Access to properties is possible, but not in scope of the builder. Did I
> misunderstood something?
>
> Kind Regards
> Matthias
> _______________________________________________
> WebTest mailing list
> [email protected]
> http://lists.canoo.com/mailman/listinfo/webtest
> _______________________________________________
> WebTest mailing list
> [email protected]
> http://lists.canoo.com/mailman/listinfo/webtest
>

Reply via email to