@Test @Category(UnitTest.class) public void testMainNoParams() { System.setSecurityManager(new CaptureExitSecurityManager()); thrown.expect(ExitException.class); thrown.expectMessage("-1"); MrGeo.main(null); }
public static void main(String[] args) { Configuration conf = HadoopUtils.createConfiguration(); int res = 0; try { res = ToolRunner.run(conf, new MrGeo(), args); } catch (Exception e) { log.error("Exception thrown", e); System.exit(-1); } System.exit(res); }
MrGeo extends Configured implements Tool { public static void main(String[] args) { Configuration conf = HadoopUtils.createConfiguration(); int res = 0; try { res = ToolRunner.run(conf, new MrGeo(), args); } catch (Exception e) { log.error("Exception thrown", e); System.exit(-1); } System.exit(res); } }
MrGeo extends Configured implements Tool { public static void main(String[] args) { Configuration conf = HadoopUtils.createConfiguration(); int res = 0; try { res = ToolRunner.run(conf, new MrGeo(), args); } catch (Exception e) { log.error("Exception thrown", e); System.exit(-1); } System.exit(res); }  }
MrGeo extends Configured implements Tool { public static void main(String[] args) { Configuration conf = HadoopUtils.createConfiguration(); int res = 0; try { res = ToolRunner.run(conf, new MrGeo(), args); } catch (Exception e) { log.error("Exception thrown", e); System.exit(-1); } System.exit(res); }  static void main(String[] args); @Override int run(String[] args); }
MrGeo extends Configured implements Tool { public static void main(String[] args) { Configuration conf = HadoopUtils.createConfiguration(); int res = 0; try { res = ToolRunner.run(conf, new MrGeo(), args); } catch (Exception e) { log.error("Exception thrown", e); System.exit(-1); } System.exit(res); }  static void main(String[] args); @Override int run(String[] args);  }