MCPcopy Create free account
hub / github.com/Mnexa-AI/e2a / TestExtractThreadInfoMissingHeaders

Function TestExtractThreadInfoMissingHeaders

internal/relay/server_test.go:222–236  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

220}
221
222func TestExtractThreadInfoMissingHeaders(t *testing.T) {
223 raw := []byte("From: alice@example.com\r\n\r\nBody only\r\n")
224
225 info := extractThreadInfo(raw)
226
227 if info.MessageID != "" {
228 t.Errorf("MessageID should be empty, got %q", info.MessageID)
229 }
230 if info.Subject != "" {
231 t.Errorf("Subject should be empty, got %q", info.Subject)
232 }
233 if info.InReplyTo != "" {
234 t.Errorf("InReplyTo should be empty, got %q", info.InReplyTo)
235 }
236}
237
238func TestExtractThreadInfoMalformed(t *testing.T) {
239 info := extractThreadInfo([]byte("not a valid email"))

Callers

nothing calls this directly

Calls 1

extractThreadInfoFunction · 0.85

Tested by

no test coverage detected