### Question:
Main { public static void main(String[] args) throws IOException, InterruptedException { CliOptions options = new CliOptions(); CmdLineParser p = new CmdLineParser(options); if (args.length == 0) { System.out.println("Usage: java -jar war-packager-cli.jar -configPath=mywar.yml [-version=1.0-SNAPSHOT] [-tmpDir=tmp]\n"); p.printUsage(System.out); return; } try { p.parseArgument(args); } catch (CmdLineException ex) { p.printUsage(System.out); throw new IOException("Failed to read command-line arguments", ex); } final Config cfg; if (options.isDemo()) { System.out.println("Running build in the demo mode"); cfg = Config.loadDemoConfig(); } else { final File configPath = options.getConfigPath(); if (configPath == null) { throw new IOException("-configPath or -demo must be defined"); } cfg = Config.loadConfig(configPath); } cfg.buildSettings.setTmpDir(options.getTmpDir()); cfg.buildSettings.setVersion(options.getVersion()); cfg.buildSettings.setMvnSettingsFile(options.getMvnSettingsFile()); cfg.buildSettings.setBOM(options.getBOMPath()); cfg.buildSettings.setEnvironmentName(options.getEnvironment()); cfg.buildSettings.setInstallArtifacts(options.isInstallArtifacts()); cfg.buildSettings.setUpdateCenterUrl(options.getUpdateCenterUrl()); if (options.batchMode) { cfg.buildSettings.addMavenOption("--batch-mode"); cfg.buildSettings.addMavenOption("-Dorg.slf4j.simpleLogger.log.org.apache.maven.cli.transfer.Slf4jMavenTransferListener=warn"); } new Builder(cfg).build(); }  static void main(String[] args);  }### Answer:
@Test public void demoShouldPass() throws Exception { Main.main(new String[] {"-demo"}); }