tatsuhiro-t/argparse4j — pull request #22 by pzelnip (2013-08-12 20:56:56+00:00)
Title: Changed HelpArgumentAction to throw exception rather than exit

- As it stood, HelpArgumentAction.run() called System.exit, regardless of
if it was triggered by a call to parseArgs() or parseArgsOrExit() The
problem with this is that the call to System.exit() makes testing any
code which triggers a call to HelpArgumentAction very difficult. With
this change, now parseArgs() raises a HelpScreenException when --help
appears as an argument, and the caller can handle this as they see fit.
parseArgsOrExit() exits the program if --help is supplied as an argument
as was the case before.