Package fitnesse

Examples of fitnesse.FitNesse


    Updater updater = null;
    //if (!arguments.isOmittingUpdates())
      //updater = new UpdaterImplementation(context);
    PageVersionPruner.daysTillVersionsExpire = arguments
        .getDaysTillVersionsExpire();
    FitNesse fitnesse = new FitNesse(context, updater);
    //update(arguments, fitnesse);
    if(!launch(arguments, context, fitnesse)) {
      throw new MojoExecutionException("FitNesse could not be launched");
    }
    return fitnesse;
View Full Code Here


    fitNesseHelper = mock(FitNesseHelper.class);
   
    FitNesseContext.Builder contextBuilder = new FitNesseContext.Builder();
    contextBuilder.port = PORT;
    FitNesseContext context = contextBuilder.createFitNesseContext();
    fitNesse = new FitNesse(context);
    fitNesse.start();
   
    mojo = new WikiMojo();
    mojo.fitNesseHelper = this.fitNesseHelper;
    mojo.port = PORT;
View Full Code Here

  @Test
  public void testLaunchFailure() throws Exception {
    Arguments arguments = new Arguments();
    //arguments.setCommand("command");
    arguments.setPort(PORT);
    FitNesse fitnesse = FitNesseMain.launchFitNesse(arguments);
    Assert.assertNotNull(fitnesse);
    try {
      FitNesseMain.launchFitNesse(arguments);
      Assert.fail("Expected MojoExecutionException");
    } catch (MojoExecutionException e) {
View Full Code Here

    FileUtil.deleteFileSystemDirectory("testFitnesseRoot");
  }

  @Test
  public void testInstallOnly() throws Exception {
    final FitNesse fitNesse = mock(FitNesse.class);
    context.withParameter(ConfigurationParameter.INSTALL_ONLY, "true");
    // Avoid doing a real update...
    context.withParameter(ConfigurationParameter.OMITTING_UPDATES, "true");

    context = spy(context);
View Full Code Here

  @Test
  public void commandArgCallsExecuteSingleCommand() throws Exception {
    context.withParameter(ConfigurationParameter.OMITTING_UPDATES, "true");
    context.withParameter(ConfigurationParameter.COMMAND, "command");

    FitNesse fitNesse = mock(FitNesse.class);
    when(fitNesse.start()).thenReturn(true);

    context = spy(context);
    doAnswer(fitNesseContextWith(fitNesse)).when(context).makeFitNesseContext();

    int exitCode = new FitNesseMain().launchFitNesse(context);
View Full Code Here

    verify(fitNesse, times(1)).stop();
  }

  @Test
  public void testDirCreations() throws IOException, PluginException {
    FitNesse fitnesse = context.makeFitNesseContext().fitNesse;
    fitnesse.start();

    try {
      assertTrue(new File("testFitnesseRoot").exists());
      assertTrue(new File("testFitnesseRoot/files").exists());
    } finally {
      fitnesse.stop();
    }
  }
View Full Code Here

  }

  @Test
  public void testIsRunning() throws Exception {
    FitNesseContext context = FitNesseUtil.makeTestContext(null, ".", "TestDir", FitNesseUtil.PORT);
    FitNesse fitnesse = context.fitNesse.dontMakeDirs();

    assertFalse(fitnesse.isRunning());

    fitnesse.start();
    assertTrue(fitnesse.isRunning());

    fitnesse.stop();
    assertFalse(fitnesse.isRunning());
  }
View Full Code Here

  @Override
  public void execute() throws BuildException {
    FitNesseContext context = FitNesseUtil.makeTestContext(null, null, null, fitnessePort);
    try {
      new FitNesse(context).stop();
      log("Sucessfully stoped Fitnesse on port " + fitnessePort);
    }
    catch (Exception e) {
      throw new BuildException("Failed to stop FitNesse. Error Msg: " + e.getMessage(), e);
    }
View Full Code Here

TOP

Related Classes of fitnesse.FitNesse

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.