[ http://jira.codehaus.org/browse/MPJAR-34?page=comments#action_62837 ]
Michael Mattox commented on MPJAR-34: ------------------------------------- We just ran across this issue on another project today. I remembered creating this feature request so I pulled it up and was amused to read through the discussions that took place a year and a half a go. A lot has changed since then, we're using Maven 2.0 but oddly enough, we still have the same problem. Was a solution ever found? If there will never be a solution we can close this issue. I'm wondering what the situation is for Maven 2. > Add an option to include test classes in jars > --------------------------------------------- > > Key: MPJAR-34 > URL: http://jira.codehaus.org/browse/MPJAR-34 > Project: maven-jar-plugin > Type: New Feature > Reporter: Michael Mattox > Assignee: Jason van Zyl > Priority: Minor > > > I have mock objects defined in my src/test tree. Other projects then use > these mock objects for their tests. With Maven, test classes are not > included in the distribution jars. Searching the mailing list, this seems to > be a common need. The only viable solution I've seen is to move the mock > objects to the src/java tree. I don't like this at all. I'd like to propose > a new property: > maven.jar.include.test.classes > it could be false by default. Setting it to true would include the test > classes in the jar. I consider test code just as important as my application > code, so this option makes a lot of sense to me. I don't see any reason not > to include, but at least adding the property would give the user the choice. -- This message is automatically generated by JIRA. - If you think it was sent incorrectly contact one of the administrators: http://jira.codehaus.org/secure/Administrators.jspa - For more information on JIRA, see: http://www.atlassian.com/software/jira
