Ejemplo n.º 1
0
  public void testLaunch_ClassNotFound() throws Exception {
    launcher.configure(getConfigPath("launch-noclass.conf"));

    try {
      launcher.launch(new String[] {});
      fail("throw ClassNotFoundException");
    } catch (ClassNotFoundException e) {
      // expected and correct
    }
  }
Ejemplo n.º 2
0
  public void testLaunch_NoSuchMethod() throws Exception {
    launcher.configure(getConfigPath("launch-nomethod.conf"));

    try {
      launcher.launch(new String[] {});
      fail("should have thrown NoSuchMethodException");
    } catch (NoSuchMethodException e) {
      // expected and correct
    }
  }
 @Before
 public void setUpPacman() {
   launcher = new Launcher();
   launcher.launch();
 }
Ejemplo n.º 4
0
  public void testLaunch_ValidEnhancedExitCode() throws Exception {
    launcher.configure(getConfigPath("valid-enh-launch-exitCode.conf"));
    launcher.launch(new String[] {});

    assertEquals("check exit code", 45, launcher.getExitCode());
  }
Ejemplo n.º 5
0
  public void testLaunch_ValidEnhanced() throws Exception {
    launcher.configure(getConfigPath("valid-enh-launch.conf"));

    launcher.launch(new String[] {});
  }