[forge-dev] JavaSourceClass parameter

Alex Soto Bueno asotobue at redhat.com
Mon Jan 30 07:21:53 EST 2017


Hi mates,

currently I am creating a command that should receive a Test Java Class as
parameter.

I have created a command with an attribute of type JavaClassSource.

@Inject
   @WithAttributes(shortName = 'j', label = "Test Class", required = true)
   private UIInput<JavaClassSource> testClass;

Then when I try to run this command from CLI the first thing I have noted
is that autocompletition of the java class name does not work, and when I
set it manually typing all characters
i.e arquillian-algeron-create-contract-fragment --consumer consumer
--provider provider --fragment myFragment --test-class
org.contract.MyContract then I got No converter found from java.lang.String
to org.jboss.forge.roaster.model.source.JavaClassSource

I think that this is because it expects the class to be found as main java
classes and not test classes, any idea on why this is happening?

Thank you so much.


More information about the forge-dev mailing list