code wiki / (root) / nx_browser_local_test.nx

nx_browser_local_test.nx

buildroot/runtime/nx_browser_local_test.nx

5745 B169 linesdepth 4pulls 5 transitivereach 0 importersview sourcekind gate/prooftopic browser
docsdependenciesstructsconstsfunctions

about

nx_browser_local_test.nx -- end-to-end "browser is up" demo. Takes a hardcoded HTML page (no network), runs it through: nx_http_response_parse (full HTTP/1.1 response → body) nx_html_to_text (HTML body → plain text) then writes the rendered text to stdout via sys_write. This is the smallest standalone proof the sovereign browser substrate end-to-end pipeline composes and produces visible output. Cardinal compliance: - bits-up substrate; no C, no third-party - per [[feedback-no-skip-paths-as-error-codes]] verdict is CAPABILITY_COMPLETENESS PARTIAL: cert validation + real DNS + real network are tracked as separate browser-arc items - F7 post-order DFS so callees are above callers Smoke asserts: * sys_write returns >= rendered_len * rendered_len matches expected ("Hello\nfrom the\nsovereign browser\n") expect_exit: 0 license_tier: ORIGINAL

dependencies 3 imports · 0 importers

nx_syscalls.nx nx_http_response_parse.nx nx_html_to_text.nx nx_browser_local_test.nx

imports: nx_syscalls.nxnx_http_response_parse.nxnx_html_to_text.nx

imported by: nobody (leaf or entry point)

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

main sys_mmap bl_build_response bl_status_line sys_mmap ↻ bl_write bl_content_type sys_mmap ↻ bl_write ↻ bl_content_length sys_mmap ↻ bl_write ↻ bl_body sys_mmap ↻ bl_write ↻ nx_browser_render_response 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 ↻ nx_html_to_text nx_html_to_text_x h2t_state_new sys_mmap ↻ sys_mmap ↻

structs

none

consts

none

functions

39func bl_write(out: *u8, off: i64, s: *u8, n: i64) -> i64
45func bl_status_line(out: *u8) -> i64
called by 1: bl_build_response calls 2: sys_mmapbl_write
56func bl_content_type(out: *u8, off: i64) -> i64
called by 1: bl_build_response calls 2: sys_mmapbl_write
69func bl_content_length(out: *u8, off: i64) -> i64
called by 1: bl_build_response calls 2: sys_mmapbl_write
82func bl_body(out: *u8, off: i64) -> i64
called by 1: bl_build_response calls 2: sys_mmapbl_write
105func bl_build_response(out: *u8) -> i64
118func nx_browser_render_response(buf: *u8, buf_len: i64, out: *u8, out_cap: i64) -> i64
126func bl_equal(got: *u8, n: i64, exp: *u8, m: i64) -> i64
called by 1: main
136func bl_expected(buf: *u8) -> i64
called by 1: main calls 1: sys_mmap
155func main() -> i64