ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stefan Bodewig <>
Subject Re: Is there a way for me to access the basedir attribute from my JUnit Tests
Date Mon, 28 Jan 2002 15:15:24 GMT
On Mon, 28 Jan 2002, <> wrote:
> I have a unit test where I need access to the directory specified by
> the ${basedir}property in build.xml.  Is there any way I can access
> that property from within my JUnit tests.

Add a <sysproperty> element to your <junit> tasks, something like

<sysproperty name="basedir" value="${basedir}" />

then it will be set as a system property and you can retrieve it via


To unsubscribe, e-mail:   <>
For additional commands, e-mail: <>

View raw message