Re: Test built jar
ping ^^ andy petrella a écrit : Hi All, I trying to have some IT tests (or look-like) on my jar file only. I was thinking that the phase verify will give me that chance but not. Here is my problem. I have a jar where some directory has to be parsed on a file pattern = I use the JarFile class, then parse it to retrieve what I need (some XML files). This code must be tested (a lot !) but I can figure out how to have my tests' classpath running on the generated test and not on target/classses. (a maven -X shows me that target/classes are used while my It test are executed using the surfire conf in the verify phase) Ideas someone ? Thanks a lot. ap - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Re: Test built jar
ok :) What I need is to be able to test the behavior of my code when the jar is attached to the classpath instead of the classes folder. Because, I have a code that parse the content of the jar where it stands to find xml files or use getResourceAsStream to get the folder. So the code checks if the context is jar or not, then execute the corresponding code. The code using getResourceAsStream is well tested but the other cannot because surefire adds the folder target/classes to the classpath rather than (in my case) the built jar. Sorry if it wasn't clear, or still not clear. If it doesn't make sense, what can I do (other than : created a project having a dependency on the to-be-tested project...) Thanks ap Wayne Fay a écrit : ping ^^ I think no one replied because your message does not make any sense (to me at least). Can you try re-writing the email and focus on what you have, what you need, and how you think Maven can help get you from A to B? Also mention what you've tried and why that didn't work or was insufficient. Wayne - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org
Test built jar
Hi All, I trying to have some IT tests (or look-like) on my jar file only. I was thinking that the phase verify will give me that chance but not. Here is my problem. I have a jar where some directory has to be parsed on a file pattern = I use the JarFile class, then parse it to retrieve what I need (some XML files). This code must be tested (a lot !) but I can figure out how to have my tests' classpath running on the generated test and not on target/classses. (a maven -X shows me that target/classes are used while my It test are executed using the surfire conf in the verify phase) Ideas someone ? Thanks a lot. ap - To unsubscribe, e-mail: users-unsubscr...@maven.apache.org For additional commands, e-mail: users-h...@maven.apache.org