@Test
public void testGetUsageInformation()
{

    List<Option> optionsIn = new ArrayList<>();
    optionsIn.add(new Option("a", "some_flag", false, "Some flag parameter"));
    optionsIn.add(new Option("b", "some_parameter", true, "Some parameter with an argument"));
    ArgumentParser argParser = new ArgumentParser("TestApp");
    argParser.addArgument(optionsIn.get(0), false);
    argParser.addArgument(optionsIn.get(1), true);
    String usage = argParser.getUsageInformation();
    assertNotNull(usage);
    assertTrue(usage.contains(String.format("usage: %s", argParser.getApplicationName())));
    for (Option option : optionsIn)
    {
        assertTrue(usage.contains(String.format("-%s,", option.getOpt())));
        assertTrue(usage.contains(String.format("--%s", option.getLongOpt())));
        assertTrue(usage.contains(option.getDescription()));
        assertTrue(!option.hasArg() || usage.contains("<arg>"));
    }
}