Package com.yahoo.jdisc.test
Class NonWorkingRequest
- java.lang.Object
-
- com.yahoo.jdisc.test.NonWorkingRequest
-
public final class NonWorkingRequest extends java.lang.Object
- Author:
- Simon Thoresen Hult
-
-
Method Summary
All Methods Static Methods Concrete Methods Modifier and Type Method Description static Request
newInstance(java.lang.String uri, com.google.inject.Module... guiceModules)
-
-
-
Method Detail
-
newInstance
public static Request newInstance(java.lang.String uri, com.google.inject.Module... guiceModules)
Factory method to create a
Request
without an associatedContainer
. The design of jDISC does not allow this, so this method internally creates TestDriver, activates a Container, and creates a new Request from that Container. Before returning, this methodcloses
the Request, and callsTestDriver.close()
on the TestDriver. This means that you MUST NOT attempt to access any Container features through the created Request. This factory is only for directed feature tests that require a non-null Request.- Parameters:
uri
- The URI string to assign to the Request.guiceModules
- The guice modules to inject into theApplication
.- Returns:
- A non-working Request.
-
-