MCPcopy Create free account
hub / github.com/clawshell/clawshell / test_extract_html_body_base64

Function test_extract_html_body_base64

src/email.rs:1136–1143  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

1134
1135 #[test]
1136 fn test_extract_html_body_base64() {
1137 let raw = b"Content-Type: text/html; charset=utf-8\r\nContent-Transfer-Encoding: base64\r\n\r\nPGgxPkhlbGxvPC9oMT4=\r\n";
1138 let (headers, body) = split_headers_and_body(raw);
1139 let (text_body, html_body) = extract_text_and_html_bodies(&headers, body);
1140
1141 assert!(text_body.is_none());
1142 assert_eq!(html_body.as_deref(), Some("<h1>Hello</h1>"));
1143 }
1144
1145 #[test]
1146 fn test_is_gmail_imap_host() {

Callers

nothing calls this directly

Calls 2

split_headers_and_bodyFunction · 0.85

Tested by

no test coverage detected