My apologies, but I'm afraid I spoke too soon.. I was running the test
successfully from Eclipse (Right click, Run As => JUnit) after removing the
duplicated xsl file from my project. Once I ran the Maven build, the test
fails inside the build with:

java.io.FileNotFoundException: class path resource [myxsl.xsl] cannot be
resolved to absolute file path because it does not reside in the file
system: jar:file:<path...>/myxsl.xsl

I am using this line in the test case to get the xsl:

import org.springframework.core.io.ClassPathResource;
import org.springframework.core.io.Resource;

...

Resource xslResource = new ClassPathResource("xslt/myxsl.xsl");

I also tried:

Resource xslResource = new ClassPathResource("/xslt/myxsl.xsl");

But got the same error.

--
View this message in context: 
http://maven.40175.n5.nabble.com/Accessing-an-xsl-in-another-project-from-a-unit-test-case-tp5711637p5711805.html
Sent from the Maven - Users mailing list archive at Nabble.com.

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

Reply via email to