MCPcopy Create free account
hub / github.com/NVIDIA/OpenShell / parse_content_length

Function parse_content_length

crates/openshell-supervisor-network/src/l7/rest.rs:2845–2851  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

2843
2844 #[test]
2845 fn parse_content_length() {
2846 let headers = "POST /api HTTP/1.1\r\nHost: example.com\r\nContent-Length: 42\r\n\r\n";
2847 match parse_body_length(headers).unwrap() {
2848 BodyLength::ContentLength(42) => {}
2849 other => panic!("Expected ContentLength(42), got {other:?}"),
2850 }
2851 }
2852
2853 #[test]
2854 fn parse_chunked() {

Callers

nothing calls this directly

Calls 1

parse_body_lengthFunction · 0.85

Tested by

no test coverage detected