DO NOT REPLY TO THIS EMAIL, BUT PLEASE POST YOUR BUG� RELATED COMMENTS THROUGH THE WEB INTERFACE AVAILABLE AT <http://issues.apache.org/bugzilla/show_bug.cgi?id=33635>. ANY REPLY MADE TO THIS MESSAGE WILL NOT BE COLLECTED AND� INSERTED IN THE BUG DATABASE.
http://issues.apache.org/bugzilla/show_bug.cgi?id=33635 Summary: Wrong OptionCount at options with aliases Product: Commons Version: unspecified Platform: PC OS/Version: Windows 2000 Status: NEW Severity: normal Priority: P2 Component: CLI AssignedTo: [email protected] ReportedBy: [EMAIL PROTECTED] If you define final Option help = obuilder .withShortName("h") .withShortName("help") .withShortName("?") .withDescription("print usage") .create(); obuilder.reset(); and call CommandLine line; line = processCommandLine(new String[] {"-hy"}); assertEquals(new String[] {"-h"}, line); then assertEquals(...); public static void assertContentsEqual(final Collection expected, final Collection found) { assertTrue(expected.containsAll(found)); assertTrue(found.containsAll(expected)); assertEquals(expected.size(), found.size()); } fails at the last line. If you do the same with final Option help = obuilder .withShortName("h") .withDescription("print usage") .create(); obuilder.reset(); then the test is green. If you retest with final Option help = obuilder .withShortName("h") .withShortName("help") .withDescription("print usage") .create(); obuilder.reset(); the test again fails. -- Configure bugmail: http://issues.apache.org/bugzilla/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the assignee for the bug, or are watching the assignee. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]
