commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Emmanuel Bourg <>
Subject Re: [cli] getParsedOptionValue
Date Thu, 07 Apr 2011 22:34:13 GMT
Hi Manuel,

> I would suggest to set the dafult type to String beause thats exactly what i
> was expacting. I would have provided a patch but i was not sure where to
> implement it (either as a fallback in CommandLine.getParsedOptionValue or in
> the Option constructor).

That's a good suggestion, could you file it in JIRA to keep track of it 
please? That should be trivial to change.

> Another thing i noticed were the Unit tests. In many test cases only
> PosixParser gets tested, but this class is marked as depracated and the
> suggested replacement, DefaultParser, doesn't get testet.

Actually there is a DefaultParserTest class that covers the new 

> Seing this i immediately thought of the new Junit 4.x features Theory and
> Parametrized Test which i wanted to test some time ago. So i ported the
> Tests to Junit 4.x (using Junit 4.8.2) and rewrote some of them using these
> features.

> If there is interest in these things i would apply this to all test and
> provide a patch for it.
> Using Junit 4.x woud also remove the dependency to the junit-addons package
> because ArrayAssert.assertEquals could be replaced by assertArrayEquals.

That's a good idea, however since the old parsers are being phased out I 
don't think it's worth investing much time on improving their tests. 
Removing the dependency on junit-addons might be interesting, I'll give 
it a look.

Emmanuel Bourg

To unsubscribe, e-mail:
For additional commands, e-mail:

View raw message