23 Testing
(require koyo/testing) | package: koyo-lib |
This module provides utilities for testing request handlers.
procedure
(make-test-request [ #:method method #:content content #:headers headers #:bindings bindings #:scheme scheme #:host host #:port port #:path path #:query query #:client-ip client-ip]) → request? method : (or/c false/c bytes? string?) = "GET" content : (or/c false/c bytes? string?) = #f
headers :
(listof (or/c header? (cons/c (or/c bytes? string?) (or/c bytes? string?)))) = null bindings : (listof binding?) = null scheme : string? = "http" host : string? = "127.0.0.1" port : (integer-in 0 65535) = 80 path : string? = "/"
query : (listof (cons/c symbol? (or/c false/c string?))) = null client-ip : string? = "127.0.0.1"
Generates request values.