Put the classpath in a string, and pass it to the tests.
--
dIon Gillard, Multitask Consulting
Blog:      http://blogs.codehaus.org/people/dion/



Bert van Brakel <[EMAIL PROTECTED]> wrote on 08/12/2003 02:27:32 PM:

> I'm using the jelly junit tags. I have a file called suite.jelly and a 
> test case which subclasses 
> org.apache.commons.jelly.tags.junit.JellyTestSuite.
> Obviously the jelly test case don't know about maven as it's part of 
jelly.
> 
> The suite.jelly I'm using is below. The pipeline generates some code and 

> test cases which I then want to compile and run
> 
> <?xml version="1.0"?>
> 
> <test:suite
>     xmlns:j="jelly:core"
> xmlns:tua="jelly:com.tuaworks.codegenerator.pattern.jbom.JBOMTagLibrary"
>     xmlns:test="jelly:junit"
>     xmlns:log="jelly:log"
>     xmlns:ant="jelly:ant"
>     >
> 
>     <test:case name="testInvokePipeline">
>         <tua:pipeline logLevel="2">
>             <log:info>Invoked the pipeline</log:info>
>             <tua:jbomXMLReader >
>                 <ant:fileset 
> 
dir="${testdir}/com/tuaworks/codegenerator/pattern/jbom/generator/castor"> 
 
> 
>                     <ant:include name="bean*.xml" /> 
>                 </ant:fileset> 
>             </tua:jbomXMLReader>
>             <tua:jbomCastorProperties /> 
>             <tua:jbomValidator />
>             <tua:jbomWriter file="${testdir}/jbom-model.html" 
> type="html"  /> 
>             <tua:jbomCastorBean />
>             <tua:jbomCastorHome />
>             <tua:jbomCastorContext />
>             <tua:jbomBeanAssociation />
>             <tua:jbomBeanValidator /> 
>             <tua:javaWriter header="${basedir}/LICENSE.txt" 
> output="${basedir}/target/generated" /> 
>             </tua:pipeline>
>         <!-- compile generated source -->
>         <echo>Compiling generated sources...</echo>
>         <!-- maven.dependency.classpath is not part of the context as 
this 
> is a jelly testcase not a maven specific one -->
> 
>         <ant:javac srcdir="${basedir}/target/generated" 
> destdir="${maven.build.dest}" classpathref="maven.dependency.classpath" 
/>
> 
>         <!-- run the compiled tests ... -->
> 
>     </test:case>
> 
> </test:suite>
> 
> 
> 
> [EMAIL PROTECTED] wrote:
> 
> >Can you show us how you're running the tests.
> >--
> >dIon Gillard, Multitask Consulting
> >Blog:      http://blogs.codehaus.org/people/dion/
> >
> >
> >
> >Bert van Brakel <[EMAIL PROTECTED]> wrote on 08/12/2003 08:57:57 AM:
> >
> > 
> >
> >>thanks but unfortunately that doesn't work ( I'd already tried that ). 

> >> From what I can see the  context created for the jelly script unit 
> >>tests is completely fresh with only the basedir ( and possibly other 
> >>system properties) being included.
> >>
> >>At this stage I'll look at using a custom tag to process the project 
> >>file and place the required variables in the context but I'd hoped 
there 
> >> 
> >>
> >
> > 
> >
> >>would already be a solution.
> >>
> >>-Bert
> >>
> >>
> >>
> >>
> >>[EMAIL PROTECTED] wrote:
> >>
> >> 
> >>
> >>>classpathref="maven.dependency.classpath" on your javac task.
> >>>--
> >>>dIon Gillard, Multitask Consulting
> >>>Blog:      http://blogs.codehaus.org/people/dion/
> >>>
> >>>
> >>>
> >>>Bert van Brakel <[EMAIL PROTECTED]> wrote on 07/12/2003 08:43:18 
PM:
> >>>
> >>>
> >>>
> >>> 
> >>>
> >>>>I'm using jelly junit to run some of my tests which include using 
the 
> >>>>ant:javac task to compile some generated code and I'm wondering how 
to 
> >>>> 
> >>>>
> >
> > 
> >
> >>>>include all the project dependencies in javac's classpath. If anyone 

> >>>>could point me in the right direction it would be most appreciated, 
as 
> >>>> 
> >>>>
> >I 
> > 
> >
> >>>> 
> >>>>
> >>>
> >>> 
> >>>
> >>>>haven't been able to find anything on the mail archives. I'm not 
> >>>> 
> >>>>
> >really 
> > 
> >
> >>>>keen to duplicate the dependencies in each junit test script.
> >>>>
> >>>>Many thanks,
> >>>>-Bert
> >>>>
> >>>>
> 
>>>>---------------------------------------------------------------------
> >>>>To unsubscribe, e-mail: [EMAIL PROTECTED]
> >>>>For additional commands, e-mail: [EMAIL PROTECTED]
> >>>>
> >>>>
> >>>>
> >>>> 
> >>>>
> >>>---------------------------------------------------------------------
> >>>To unsubscribe, e-mail: [EMAIL PROTECTED]
> >>>For additional commands, e-mail: [EMAIL PROTECTED]
> >>>
> >>>
> >>>
> >>>
> >>> 
> >>>
> >>
> >>---------------------------------------------------------------------
> >>To unsubscribe, e-mail: [EMAIL PROTECTED]
> >>For additional commands, e-mail: [EMAIL PROTECTED]
> >>
> >> 
> >>
> >
> >
> >---------------------------------------------------------------------
> >To unsubscribe, e-mail: [EMAIL PROTECTED]
> >For additional commands, e-mail: [EMAIL PROTECTED]
> >
> >
> > 
> >
> 
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to