public abstract class NoAppWebsocketTestingBase extends AppBasedWebsocketTestingBase<DefaultRequestContext,DefaultWebsocketContext>
| Modifier and Type | Field and Description |
|---|---|
protected org.slf4j.Logger |
logger |
spincastHttpClientUtilsspincastConfig| Constructor and Description |
|---|
NoAppWebsocketTestingBase() |
| Modifier and Type | Method and Description |
|---|---|
void |
beforeClass()
Called before the tests of the class are ran.
|
protected void |
beforeStartServer()
Allows some initialization to be run once the Guice context
is created, but before the Server is started.
|
void |
beforeTest()
Ran before every test.
|
protected void |
callAppMainMethod()
Starts the application.
|
protected void |
clearRoutes() |
protected AppTestingConfigs |
getAppTestingConfigs()
We force test classes to provide information about
the required testing configurations.
|
protected String[] |
getMainArgs() |
protected Class<? extends SpincastConfig> |
getTestingConfigImplClass() |
protected boolean |
removeSpincastRoutesToo()
Should the default Spincast Routes
be removed too? Or only the custom ones?
|
protected void |
startServer() |
closeAllWebsocketEndpoints, getExtraOverridingModule, getExtraOverridingModule3, getSecSocketKey, getServerPingIntervalSeconds, getSpincastHttpClientUtils, getSpincastUndertowConfigImplementation, getWebsocketTestExpectedWebsocketV13AcceptHeaderValue, validateIsNotWebsocketUpgradeHttpResponse, validateIsWebsocketUpgradeHttpResponse, websocketafterClass, clearPreviousResponseCookies, CONNECT, CONNECT, CONNECT, createInjector, createTestUrl, createTestUrl, createTestUrl, DELETE, DELETE, DELETE, formatDate, GET, GET, GET, getCookieFactory, getExtraExactBindingsToRemoveBeforePlugins, getExtraPlugins, getGuiceTweakerExtraOverridingModule, getGuiceTweakerExtraPlugins, getHttpClient, getPreviousResponseCookie, getPreviousResponseCookies, getRouter, getServer, getTestingConfigImplementationClass, HEAD, HEAD, HEAD, isDisableBindCurrentClass, isDisableSllCetificateErrors, isSetSecureFalseOnCookiesFromBag, OPTIONS, OPTIONS, OPTIONS, parseDate, PATCH, PATCH, PATCH, POST, POST, POST, PUT, PUT, PUT, saveResponseCookies, stopServer, TRACE, TRACE, TRACE, validateCreatedInjector, websocket, websocketaddExtraSystemProperties, afterClassLoops, afterTest, beforeClassException, createGuiceTweaker, createTestingFilePath, createTestingFilePath, deleteTempDir, getExtraSystemProperties, getGuiceTweakerFromThreadLocal, getInjector, getSpincastConfig, getTestingWritableDir, resetSystemProperties, testFailureprotected final AppTestingConfigs getAppTestingConfigs()
AppBasedTestingBaseThe bindings for those components will be automatically created.
getAppTestingConfigs in class AppBasedTestingBase<DefaultRequestContext,DefaultWebsocketContext>null
to disable this process (you will then have to add the
required config bindings by yourself).protected Class<? extends SpincastConfig> getTestingConfigImplClass()
protected final void callAppMainMethod()
AppBasedTestingBase
In this method, you should call your
application main() method.
There is no need to start the
Server here, since the target
application is supposed to do it by itself,
in general in an "@Inject init()"
method!
callAppMainMethod in class AppBasedTestingBase<DefaultRequestContext,DefaultWebsocketContext>protected String[] getMainArgs()
public void beforeClass()
BeforeAfterClassMethodsProviderbeforeClass in interface BeforeAfterClassMethodsProviderbeforeClass in class AppBasedTestingBase<DefaultRequestContext,DefaultWebsocketContext>protected void startServer()
protected void beforeStartServer()
public void beforeTest()
beforeTest in class AppBasedWebsocketTestingBase<DefaultRequestContext,DefaultWebsocketContext>protected void clearRoutes()
protected boolean removeSpincastRoutesToo()
Copyright © 2018. All rights reserved.