[ http://jira.codehaus.org/browse/MPGENAPP-24?page=comments#action_49257 ]
Felipe Leme commented on MPGENAPP-24: ------------------------------------- Arnauld, I have createad a class that sets the System.in to always return enter: package org.apache.maven.genapp.testing; import java.io.BufferedInputStream; import java.io.IOException; import java.io.InputStream; public class NewlinerInputStream extends BufferedInputStream { private static final InputStream SYSTEM_IN = System.in; private static final NewlinerInputStream THE_INSTANCE = new NewlinerInputStream(SYSTEM_IN); public static void replaceSystemIn() { System.setIn( THE_INSTANCE ); } public NewlinerInputStream(InputStream in) { super(in); } public synchronized int read(byte[] b, int off, int len) throws IOException { b[0] = '\n'; return 1; } } And then on maven.xml I used: <goal name="test-genapp" prereqs="clean,java:compile"> <j:invokeStatic className="org.apache.maven.genapp.testing.NewlinerInputStream" method="replaceSystemIn"/> <attainGoal name="genapp"/> </goal> But I got a ClassNotFoundException: BUILD FAILED File...... e:\cvs\maven\svn\plugins\trunk\genapp\src\plugin-test\basedirTest\mav en.xml Element... j:invokeStatic Line...... 30 Column.... 110 org.apache.maven.genapp.testing.NewlinerInputStream Total time: 2 seconds Finished at: Tue Oct 25 18:31:39 BRST 2005 Do you know how should I set Jelly to use that class (which is under src/main on the plugin - I have also set the <build> on the testcase's POM to that value)? Thks, -- Felipe > Allow project to be generated somewhere else ${basedir} > ------------------------------------------------------- > > Key: MPGENAPP-24 > URL: http://jira.codehaus.org/browse/MPGENAPP-24 > Project: maven-genapp-plugin > Type: Improvement > Versions: 2.2 > Reporter: Felipe Leme > Assignee: Felipe Leme > Priority: Minor > Fix For: 2.3 > > Original Estimate: 30 minutes > Remaining: 30 minutes > > When you run genapp, it creates the new project in the current directory. I > see at least one situation (which is why I'm creating this issue) where that > is not desired: when creating test cases for this plugin! > So, I will create a maven.genapp.basedir property to fix this issue. -- 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 --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]