[Webtest] problem with properties

Julien Chambert webtest@lists.canoo.com
Wed, 13 Sep 2006 11:27:43 +0200


------=_Part_93457_12228569.1158139663783
Content-Type: text/plain; charset=ISO-8859-1; format=flowed
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

that's it.
thank you


2006/9/13, Paul King <paulk@asert.com.au>:
>
>
> Is it just a case of round versus curly braces?
>
> Julien Chambert wrote:
> > hello everybody,
> >
> >
> >       i have a problem: I don't manage to handle my properties files.
> >
> >    here is my code
> > -------------------------------------------------------------------
> >      test.xml
> > -----------------------------------------------------------------
> > <project name="FullSuite" default="testSuite" basedir=".">
> >
> >   <property name="test.xml" value="tests/test.xml" />
> >
> >   <target name="testSuite" >
> >     <ant antfile="${test.xml}">
> >       <property file="test_properties/Mytest.properties"/>
> >     </ant>
> >   </target>
> >
> > </project>
> >
> -----------------------------------------------------------------------------
> >
> >       tests/test.xml
> >
> -----------------------------------------------------------------------------
> > <?xml version="1.0"?>
> >
> > <!DOCTYPE project [
> >   <!ENTITY config   SYSTEM "config.xml ">
> >   <!ENTITY testVolontaire   SYSTEM "testVolontaire.xml">
> >   <!ENTITY testRecrut   SYSTEM "testRecrut.xml">
> >   <!ENTITY verif SYSTEM "verif.xml">
> > ]>
> >
> >
> > <project name="test" default="oneTest" basedir="..">
> >     <property name="webtest.home" location="C:/canoo" />
> >     <import file="${webtest.home }/lib/taskdef.xml"/>
> >     <target name="oneTest">
> >         <webtest name="$(test.Name)">
> >             &config;
> >             <steps>
> >                 <ifStep description="if volontaire: $( test.volontaire)"
> > test="$(test.volontaire)">
> >                     &testVolontaire;
> >                 </ifStep>
> >                 <ifStep description="else" unless="$(test.volontaire )">
> >                     &testRecrut;
> >                 </ifStep>
> >                 &verif;
> >             </steps>
> >         </webtest>
> >     </target>
> > </project>
> >
> ----------------------------------------------------------------------------------------------------------------
> > properties/MyTest.properties
> >
> --------------------------------------------------------------------------------------------------------------
> >
> > page.volontaire=t.php
> > page.recrutement=t_recrut.php
> > page.test=test-form/test.html
> >
> > test.Name=MyTest
> > test.volontaire=true
> > test.ResultOk=true
> >
> ---------------------------------------------------------------------------------------------------------------
> >
> >
> > the problem is that it doesn't care of my properties. for example it
> > displaies:
> >           [ifStep]  INFO (com.canoo.webtest.steps.Step) - >>>> Start
> > Step: ifStep "if volontaire: $(test.volontaire )" (1/122)
> > it's the same for test.Name.
> > i'm pretty sure it doesn't come from the properties file because in
> > testRecrut.xml, a property page.volontaire is used and works fine.
> >
> >  I don't understand where is the problem.
> >
> >  thank you for your future answers
> >
> > Julien Chambert
> >
> >
>
> _______________________________________________
> WebTest mailing list
> WebTest@lists.canoo.com
> http://lists.canoo.com/mailman/listinfo/webtest
>

------=_Part_93457_12228569.1158139663783
Content-Type: text/html; charset=ISO-8859-1
Content-Transfer-Encoding: 7bit
Content-Disposition: inline

that's it.<br>thank you<br><br><br><div><span class="gmail_quote">2006/9/13, Paul King &lt;<a href="mailto:paulk@asert.com.au">paulk@asert.com.au</a>&gt;:</span><blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;">
<br>Is it just a case of round versus curly braces?<br><br>Julien Chambert wrote:<br>&gt; hello everybody,<br>&gt;<br>&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; i have a problem: I don't manage to handle my properties files.<br>&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;here is my code
<br>&gt; -------------------------------------------------------------------<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;test.xml<br>&gt; -----------------------------------------------------------------<br>&gt; &lt;project name=&quot;FullSuite&quot; default=&quot;testSuite&quot; basedir=&quot;.&quot;&gt;
<br>&gt;<br>&gt;&nbsp;&nbsp; &lt;property name=&quot;test.xml&quot; value=&quot;tests/test.xml&quot; /&gt;<br>&gt;<br>&gt;&nbsp;&nbsp; &lt;target name=&quot;testSuite&quot; &gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &lt;ant antfile=&quot;${test.xml}&quot;&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;property file=&quot;test_properties/Mytest.properties&quot;/&gt;
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/ant&gt;<br>&gt;&nbsp;&nbsp; &lt;/target&gt;<br>&gt;<br>&gt; &lt;/project&gt;<br>&gt; -----------------------------------------------------------------------------<br>&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; tests/test.xml<br>&gt; -----------------------------------------------------------------------------
<br>&gt; &lt;?xml version=&quot;1.0&quot;?&gt;<br>&gt;<br>&gt; &lt;!DOCTYPE project [<br>&gt;&nbsp;&nbsp; &lt;!ENTITY config&nbsp;&nbsp; SYSTEM &quot;config.xml &quot;&gt;<br>&gt;&nbsp;&nbsp; &lt;!ENTITY testVolontaire&nbsp;&nbsp; SYSTEM &quot;testVolontaire.xml
&quot;&gt;<br>&gt;&nbsp;&nbsp; &lt;!ENTITY testRecrut&nbsp;&nbsp; SYSTEM &quot;testRecrut.xml&quot;&gt;<br>&gt;&nbsp;&nbsp; &lt;!ENTITY verif SYSTEM &quot;verif.xml&quot;&gt;<br>&gt; ]&gt;<br>&gt;<br>&gt;<br>&gt; &lt;project name=&quot;test&quot; default=&quot;oneTest&quot; basedir=&quot;..&quot;&gt;
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &lt;property name=&quot;webtest.home&quot; location=&quot;C:/canoo&quot; /&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &lt;import file=&quot;${webtest.home }/lib/taskdef.xml&quot;/&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &lt;target name=&quot;oneTest&quot;&gt;
<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;webtest name=&quot;$(test.Name)&quot;&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &amp;config;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;steps&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;ifStep description=&quot;if volontaire: $( test.volontaire)&quot;
<br>&gt; test=&quot;$(test.volontaire)&quot;&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &amp;testVolontaire;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/ifStep&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;ifStep description=&quot;else&quot; unless=&quot;$(test.volontaire
 )&quot;&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &amp;testRecrut;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/ifStep&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &amp;verif;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/steps&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/webtest&gt;<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp; &lt;/target&gt;
<br>&gt; &lt;/project&gt;<br>&gt; ----------------------------------------------------------------------------------------------------------------<br>&gt; properties/MyTest.properties<br>&gt; --------------------------------------------------------------------------------------------------------------
<br>&gt;<br>&gt; page.volontaire=t.php<br>&gt; page.recrutement=t_recrut.php<br>&gt; page.test=test-form/test.html<br>&gt;<br>&gt; test.Name=MyTest<br>&gt; test.volontaire=true<br>&gt; test.ResultOk=true<br>&gt; ---------------------------------------------------------------------------------------------------------------
<br>&gt;<br>&gt;<br>&gt; the problem is that it doesn't care of my properties. for example it<br>&gt; displaies:<br>&gt;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; [ifStep]&nbsp;&nbsp;INFO (com.canoo.webtest.steps.Step) - &gt;&gt;&gt;&gt; Start<br>&gt; Step: ifStep &quot;if volontaire: $(
test.volontaire )&quot; (1/122)<br>&gt; it's the same for test.Name.<br>&gt; i'm pretty sure it doesn't come from the properties file because in<br>&gt; testRecrut.xml, a property page.volontaire is used and works fine.<br>
&gt;<br>&gt;&nbsp;&nbsp;I don't understand where is the problem.<br>&gt;<br>&gt;&nbsp;&nbsp;thank you for your future answers<br>&gt;<br>&gt; Julien Chambert<br>&gt;<br>&gt;<br><br>_______________________________________________<br>WebTest mailing list
<br><a href="mailto:WebTest@lists.canoo.com">WebTest@lists.canoo.com</a><br><a href="http://lists.canoo.com/mailman/listinfo/webtest">http://lists.canoo.com/mailman/listinfo/webtest</a><br></blockquote></div><br>

------=_Part_93457_12228569.1158139663783--