public class RestxSpecTestServer extends Object
| Modifier and Type | Class and Description |
|---|---|
static class |
RestxSpecTestServer.RunningServer |
static interface |
RestxSpecTestServer.RunningServerSettings |
| Constructor and Description |
|---|
RestxSpecTestServer(String routerPath,
int port,
WebServerSupplier webServerSupplier,
Factory factory)
Constructs a new RestxSpecRule.
|
| Modifier and Type | Method and Description |
|---|---|
static void |
main(String[] args) |
static RestxSpecTestServer |
newInstance()
A shortcut for new RestxSpecRule("/api", 8076, queryByClass(WebServerSupplier.class), Factory.getInstance())
|
static RestxSpecTestServer |
newInstance(WebServerSupplier webServerSupplier)
A shortcut for new RestxSpecRule("/api", 8076, webServerSupplier, Factory.getInstance())
|
RestxSpecTestServer.RunningServer |
start() |
public RestxSpecTestServer(String routerPath, int port, WebServerSupplier webServerSupplier, Factory factory)
routerPath - the path at which restx router is mounted. eg '/api'webServerSupplier - a supplier of WebServer, you can use #jettyWebServerSupplier for jetty.factory - the restx Factory to use to find GivenSpecRuleSupplier s when executing the spec.
This is not used for the server itself.public static RestxSpecTestServer newInstance()
public static RestxSpecTestServer newInstance(WebServerSupplier webServerSupplier)
public RestxSpecTestServer.RunningServer start() throws Exception
ExceptionCopyright © 2017. All Rights Reserved.