[MPLUGIN-98] Remove javadoc inline tags from output of help mojo
git-svn-id: https://svn.apache.org/repos/asf/maven/plugin-tools/trunk@643559 13f79535-47bb-0310-9956-ffa450edef68master
parent
6ebf227d09
commit
0d658ca66e
|
|
@ -35,6 +35,7 @@ import javax.swing.text.html.parser.ParserDelegator;
|
|||
import org.apache.maven.plugin.descriptor.MojoDescriptor;
|
||||
import org.apache.maven.plugin.descriptor.Parameter;
|
||||
import org.apache.maven.plugin.descriptor.PluginDescriptor;
|
||||
import org.apache.maven.tools.plugin.util.PluginUtils;
|
||||
import org.codehaus.plexus.logging.AbstractLogEnabled;
|
||||
import org.codehaus.plexus.logging.Logger;
|
||||
import org.codehaus.plexus.logging.console.ConsoleLogger;
|
||||
|
|
@ -524,7 +525,7 @@ public class PluginHelpGenerator
|
|||
}
|
||||
};
|
||||
|
||||
parser.parse( new StringReader( str ), htmlCallback, true );
|
||||
parser.parse( new StringReader( PluginUtils.makeHtmlValid( str ) ), htmlCallback, true );
|
||||
|
||||
return StringUtils.replace( sb.toString(), "\"", "'" ); // for CDATA
|
||||
}
|
||||
|
|
|
|||
|
|
@ -39,5 +39,9 @@ public class PluginHelpGeneratorTest
|
|||
// wrong HTML
|
||||
javadoc = "Generates <i>something</i> <b> for the project.";
|
||||
assertEquals( "Generates something for the project.", PluginHelpGenerator.toText( javadoc ) );
|
||||
|
||||
// javadoc inline tags
|
||||
javadoc = "Generates {@code something} for the project.";
|
||||
assertEquals( "Generates something for the project.", PluginHelpGenerator.toText( javadoc ) );
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue