object TestClient extends Serializable
Linear Supertypes
Ordering
- Alphabetic
- By Inheritance
Inherited
- TestClient
- Serializable
- Serializable
- AnyRef
- Any
- Hide All
- Show All
Visibility
- Public
- All
Value Members
-
final
def
!=(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
##(): Int
- Definition Classes
- AnyRef → Any
-
final
def
==(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
def
addRequestResponse(request: Request, response: Response): ZIO[TestClient, Nothing, Unit]
Adds an exact 1-1 behavior
Adds an exact 1-1 behavior
- request
The request that will trigger the response
- response
The response to be returned when a user submits the response
TestClient.addRequestResponse(Request.get(URL.root), Response.ok)
Example: -
def
addRoute[R](route: Route[R, Response]): ZIO[R with TestClient, Nothing, Unit]
Adds a route definition to handle requests that are submitted by test cases
Adds a route definition to handle requests that are submitted by test cases
- R
Environment of the new route
- route
New route to be added to the TestClient
TestClient.addRoute { Method.ANY / trailing -> handler(Response.ok) }
Example: -
def
addRoutes[R](route: Route[R, Response], routes: Route[R, Response]*): ZIO[R with TestClient, Nothing, Unit]
Adds routes to handle requests that are submitted by test cases
Adds routes to handle requests that are submitted by test cases
- R
Environment of the new route
- routes
New routes to be added to the TestClient
TestClient.addRoutes { Routes( Method.GET / trailing -> handler { Response.text("fallback") }, Method.GET / "hello" / "world" -> handler { Response.text("Hey there!") }, ) }
Example: - def addRoutes(app: Routes[Any, Response]): ZIO[TestClient, Nothing, Unit]
-
final
def
asInstanceOf[T0]: T0
- Definition Classes
- Any
-
def
clone(): AnyRef
- Attributes
- protected[lang]
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native() @IntrinsicCandidate()
-
final
def
eq(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
def
equals(arg0: Any): Boolean
- Definition Classes
- AnyRef → Any
-
final
def
getClass(): Class[_]
- Definition Classes
- AnyRef → Any
- Annotations
- @native() @IntrinsicCandidate()
-
def
hashCode(): Int
- Definition Classes
- AnyRef → Any
- Annotations
- @native() @IntrinsicCandidate()
- def installSocketApp(app: WebSocketApp[Any]): ZIO[TestClient, Nothing, Unit]
-
final
def
isInstanceOf[T0]: Boolean
- Definition Classes
- Any
- val layer: ZLayer[Any, Nothing, zio.&[TestClient, Client]]
-
final
def
ne(arg0: AnyRef): Boolean
- Definition Classes
- AnyRef
-
final
def
notify(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @IntrinsicCandidate()
-
final
def
notifyAll(): Unit
- Definition Classes
- AnyRef
- Annotations
- @native() @IntrinsicCandidate()
-
final
def
synchronized[T0](arg0: ⇒ T0): T0
- Definition Classes
- AnyRef
-
def
toString(): String
- Definition Classes
- AnyRef → Any
-
final
def
wait(arg0: Long, arg1: Int): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )
-
final
def
wait(arg0: Long): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... ) @native()
-
final
def
wait(): Unit
- Definition Classes
- AnyRef
- Annotations
- @throws( ... )