code wiki / (root) / nx_http_response_parse_test.nx

nx_http_response_parse_test.nx

buildroot/runtime/nx_http_response_parse_test.nx

9737 B270 linesdepth 3pulls 3 transitivereach 0 importersview sourcekind gate/prooftopic http
docsdependenciesstructsconstsfunctions

about

nx_http_response_parse_test.nx -- KATs for HTTP/1.1 client-side response parser. Covers: K1 minimal 200 OK with Content-Length + body -> verdict OK, code=200, body_len=5, body bytes = "hello" K2 404 Not Found with Content-Length=0 -> verdict OK, code=404, body_len=0 K3 chunked-encoded body (two chunks) -> dechunk yields concatenated bytes K4 case-insensitive header lookup -> finds "Content- Type" via lowercase query K5 malformed status line (bad version) -> verdict ERR_ BAD_VERSION K6 Transfer-Encoding: chunked classification -> transfer_kind == NX_HTTP_BODY_CHUNKED Built per F7 post-order DFS. expect_exit: 0 license_tier: ORIGINAL

dependencies 2 imports · 0 importers

nx_syscalls.nx nx_http_response_parse.nx nx_http_response_parse_test.nx

imports: nx_syscalls.nxnx_http_response_parse.nx

imported by: nobody (leaf or entry point)

call flow from main pre-order; caps 40 nodes / depth 6 declared; ↻ = already shown

main k1_minimal_200_hello sys_mmap t_make_200_hello sys_mmap ↻ t_write_str nx_http_resp_alloc sys_mmap ↻ nx_http_response_parse sys_mmap ↻ nx_http_resp_parse_status_ sys_mmap ↻ nx_http_resp_parse_dec nx_http_resp_is_digit nx_http_resp_skip_ows nx_http_resp_find_crlf nx_http_resp_classify_body sys_mmap ↻ nx_http_resp_parse_header_ nx_http_resp_find_byte nx_http_resp_skip_ows ↻ nx_http_resp_find_crlf ↻ nx_http_resp_cieq nx_http_resp_lower nx_http_resp_parse_dec ↻ k2_404_empty sys_mmap ↻ t_make_404_empty sys_mmap ↻ t_write_str ↻ nx_http_resp_alloc ↻ nx_http_response_parse ↻ k3_chunked_decode sys_mmap ↻ t_make_chunked_body sys_mmap ↻ t_write_str ↻ nx_http_dechunk sys_mmap ↻ nx_http_resp_parse_hex

structs

none

consts

none

functions

27func t_write_str(out: *u8, off: i64, s: *u8, n: i64) -> i64
33func t_make_200_hello(out: *u8) -> i64
58func t_make_404_empty(out: *u8) -> i64
called by 1: k2_404_empty calls 2: sys_mmapt_write_str
82func t_make_chunked(out: *u8) -> i64
106func t_make_chunked_body(out: *u8) -> i64
127func t_make_200_with_ct(out: *u8) -> i64
161func t_make_bad_version(out: *u8) -> i64
177func k1_minimal_200_hello() -> i64
191func k2_404_empty() -> i64
203func k3_chunked_decode() -> i64
217func k4_header_lookup_ci() -> i64
237func k5_bad_version_rejected() -> i64
246func k6_chunked_classification() -> i64
256func main() -> i64