Examples of sentData()


Examples of fitnesse.http.MockResponseSender.sentData()

    // import a second time... nothing was modified
    createResponder();
    response = makeSampleResponse(baseUrl);
    sender = new MockResponseSender();
    sender.doSending(response);
    String content = sender.sentData();

    assertSubString("<html>", content);
    assertSubString("Wiki Import", content);

    assertSubString("PageTwo", content);
View Full Code Here

Examples of fitnesse.http.MockResponseSender.sentData()

    MockRequest request = makeRequest(baseUrl + "PageOne");

    Response response = responder.makeResponse(FitNesseUtil.makeTestContext(testData.localRoot), request);
    MockResponseSender sender = new MockResponseSender();
    sender.doSending(response);
    String content = sender.sentData();

    assertNotNull(testData.pageTwo.getChildPage("ChildOne"));
    assertSubString("PageTwo.ChildOne", content);
    assertSubString("ChildOne", content);
  }
View Full Code Here

Examples of fitnesse.http.MockResponseSender.sentData()

    String remoteUrl = baseUrl + "PageDoesntExist";
    Response response = makeSampleResponse(remoteUrl);

    MockResponseSender sender = new MockResponseSender();
    sender.doSending(response);
    String content = sender.sentData();
    assertSubString("The remote resource, " + remoteUrl + ", was not found.", content);
  }

  @Test
  public void testErrorMessageForBadUrlProvided() throws Exception {
View Full Code Here

Examples of fitnesse.http.MockResponseSender.sentData()

    String remoteUrl = baseUrl + "+blah";
    Response response = makeSampleResponse(remoteUrl);

    MockResponseSender sender = new MockResponseSender();
    sender.doSending(response);
    String content = sender.sentData();
    assertSubString("The URL's resource path, +blah, is not a valid WikiWord.", content);
  }

  @Test
  public void testListOfOrphanedPages() throws Exception {
View Full Code Here

Examples of fitnesse.http.MockResponseSender.sentData()

  private String runSuite() throws Exception {
    Response response = responder.makeResponse(context, request);
    MockResponseSender sender = new MockResponseSender();
    sender.doSending(response);
    String results = sender.sentData();
    return results;
  }


  @Test
View Full Code Here

Examples of fitnesse.http.MockResponseSender.sentData()

    makeSecurePage(testData.remoteRoot);

    Response response = makeSampleResponse(baseUrl);
    MockResponseSender sender = new MockResponseSender();
    sender.doSending(response);
    String content = sender.sentData();
    checkRemoteLoginForm(content);
  }

  @Test
  public void testUnauthorizedResponseFromNonRoot() throws Exception {
View Full Code Here

Examples of fitnesse.http.MockResponseSender.sentData()

    makeSecurePage(childPage);

    Response response = makeSampleResponse(baseUrl);
    MockResponseSender sender = new MockResponseSender();
    sender.doSending(response);
    String content = sender.sentData();
    assertSubString("The wiki at " + baseUrl + "PageOne requires authentication.", content);
    assertSubString("<form", content);
  }

  @Test
View Full Code Here

Examples of fitnesse.http.MockResponseSender.sentData()

    request.addInput("remoteUsername", "joe");
    request.addInput("remotePassword", "blow");
    Response response = getResponse(request);
    MockResponseSender sender = new MockResponseSender();
    sender.doSending(response);
    String content = sender.sentData();

    assertNotSubString("requires authentication", content);
    assertSubString("3 pages were imported.", content);
  }
View Full Code Here

Examples of fitnesse.http.MockResponseSender.sentData()

  public void testException() throws Exception {
    exception = new Exception("test exception");
    response = (ChunkedResponse)responder.makeResponse(context, new MockRequest());
    MockResponseSender sender = new MockResponseSender();
    sender.doSending(response);
    String responseSender = sender.sentData();
    assertSubString("test exception", responseSender);
  }

  @Test
  public void chunkingShouldBeTurnedOffIfnochunkParameterIsPresent() throws Exception {
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. 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.