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

Function html_escape_basic

crates/openshell-server/src/auth/http.rs:582–588  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

580
581 #[test]
582 fn html_escape_basic() {
583 assert_eq!(html_escape("hello"), "hello");
584 assert_eq!(html_escape("<b>bold</b>"), "&lt;b&gt;bold&lt;/b&gt;");
585 assert_eq!(html_escape("a&b"), "a&amp;b");
586 assert_eq!(html_escape("a\"b"), "a&quot;b");
587 assert_eq!(html_escape("a'b"), "a&#x27;b");
588 }
589}

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected