Package net.officefloor.server.http
Class HttpClientRule
java.lang.Object
net.officefloor.server.http.AbstractHttpClientJUnit<HttpClientRule>
net.officefloor.server.http.HttpClientRule
- All Implemented Interfaces:
org.junit.rules.TestRule
public class HttpClientRule
extends AbstractHttpClientJUnit<HttpClientRule>
implements org.junit.rules.TestRule
- Author:
- Daniel Sagenschneider
-
Constructor Summary
ConstructorsConstructorDescriptionInstantiate for non-secure (HTTP) connection toHttpServer.HttpClientRule(boolean isSecure) Instantiate with flagging if secure (HTTPS) connection toHttpServer.HttpClientRule(boolean isSecure, int port) Instantiate indicating the server port. -
Method Summary
Modifier and TypeMethodDescriptionorg.junit.runners.model.Statementapply(org.junit.runners.model.Statement base, org.junit.runner.Description description) Methods inherited from class net.officefloor.server.http.AbstractHttpClientJUnit
closeHttpClient, execute, followRedirects, getHttpClient, openHttpClient, timeout, url
-
Constructor Details
-
HttpClientRule
public HttpClientRule()Instantiate for non-secure (HTTP) connection toHttpServer. -
HttpClientRule
public HttpClientRule(boolean isSecure) Instantiate with flagging if secure (HTTPS) connection toHttpServer.- Parameters:
isSecure- Indicates if secure (HTTPS).
-
HttpClientRule
public HttpClientRule(boolean isSecure, int port) Instantiate indicating the server port.- Parameters:
isSecure- Indicates if secure (HTTPS).port- Server port to connect.
-
-
Method Details
-
apply
public org.junit.runners.model.Statement apply(org.junit.runners.model.Statement base, org.junit.runner.Description description) - Specified by:
applyin interfaceorg.junit.rules.TestRule
-