Examples of DummyFakeRequest


Examples of se.dannej.fakehttpserver.expect.DummyFakeRequest

  private static final String UNEXPECTED_METHOD = "GET";
  private static final String EXPECTED_METHOD = "POST";

  @Test
  public void matchesReturnsFalseIfExpectedMethodNameDoesNotEqualMethodOfRequest() {
    DummyFakeRequest requestWithUnexpectedMethod = newRequest().withMethod(UNEXPECTED_METHOD);
    boolean result = headMatcher(EXPECTED_METHOD).matches(requestWithUnexpectedMethod);
    assertThat(result, is(false));
  }
View Full Code Here

Examples of se.dannej.fakehttpserver.expect.DummyFakeRequest

    assertThat(result, is(false));
  }

  @Test
  public void matchesReturnsTrueIfExpectedMethodNameEqualsMethodOfRequest() {
    DummyFakeRequest requestWithExpectedMethod = newRequest().withMethod(EXPECTED_METHOD);
    boolean result = headMatcher(EXPECTED_METHOD).matches(requestWithExpectedMethod);
    assertThat(result, is(true));
  }
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.