You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@maven.apache.org by michalb_cz <mb...@atlas.cz> on 2008/11/12 12:41:08 UTC

${project.build.testResources.*} property accessor

Lo everyone,

I need to refer to src/test/resources directory in my pom.xml in some plugin
configuration settings.
So I was trying

<somePlugin>
   <something>...</something>   
  
<directory>${project.build.testResources.resources.0.directory}${file.separator}someFile.xml
   </directory>
</somePlugin>

i am expecting that text in <directory> evaluate to for example
C:\myproject\src\test\resources\someFile.xml

${project.build.testResources} return xml structure (i evaluate that through
mvn help:evaluate)

<resources>
  <resource>
      <includes/>
      <excludes/>
      <directory>something.../src/test/resources</directory>
      <filtering>false</filtering>
  </resource>
</resources>

To find out testSource directory or source directory is easy
(${project.build.sourceDirectory}, but to find out resource directories
seems impossible when you cannot get value from lists (eg. resources is list
of resource) in xml (see http://jira.codehaus.org/browse/PLXUTILS-37)

What is the way to find out testResources directory ie. src/test/resources?

Thanks...
-- 
View this message in context: http://n2.nabble.com/%24%7Bproject.build.testResources.*%7D-property-accessor-tp1489348p1489348.html
Sent from the maven users mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscribe@maven.apache.org
For additional commands, e-mail: users-help@maven.apache.org