Menu

#11 junit.cent: testcase dependencies

open
nobody
None
3
2002-10-29
2002-10-29
No

I'd like to be able to specify jars that only the
testcases have access to (like easymock). It should
not be used when compiling or generating javadoc.

What I mean is that I'd like to do that:

<source dir="./src">
<targets dir="./src/targets"/>
<java dir="./src/java"/>
<test dir="./src/testcases">
<library dir="./lib/test/"/>
</test>
<documentation dir="./src/documentation">
<content dir="./src/documentation/xdocs">
<xdocs dir="./src/documentation/xdocs"/>
...

but in another directory, because the problem here is
that javac would have access to the libraries in
lib/test because test is a subdirectory of lib. should
it be ./test/lib maybe.

Discussion

  • Nick Chalko

    Nick Chalko - 2002-10-29
    • priority: 5 --> 3
     
  • Nick Chalko

    Nick Chalko - 2002-10-29

    Logged In: YES
    user_id=27898

    module.xml doesn't look like that now.
    Here is a sample
    <project name="smoketest">

    <version major="0"
    minor="0"
    fix ="1"
    tag="alpha1-dev"/>

    <package>smoketest</package>

    <ant target="gump" vm="1.2"/>

    <depend project="log4j" version="1.2.4"/>
    <depend project="helloworld" version="supplied"
    export="true"/>

    <!-- Work dirs to be included in classpath -->
    <work nested="build/classes"/>

    <home nested="build"/>

    <code type="java/plain" dir="src/java"/>
    <test type="test/junit" dir="src/test"/>
    <documentation type="xml/forrest"
    dir="src/documentation"/>

    </project>

    I suppose we could add a type="test" to the depend tag.

     
  • Stephane Zermatten

    Logged In: YES
    user_id=186210

    that would be really cool; sorry I didn't check the cvs
    before filing the request.

    note that a type="test" would still not make it possible to
    use depend to load jars for exampes (in lib/examples), what
    about a dir="./lib/test" that could become a
    dir="./example/lib" that would be more powerful (but less
    simple to use) ?

    if you tell me what kind changes you have in mind, I could
    do them and send you a patch.

     

Log in to post a comment.

MongoDB Logo MongoDB