MCPcopy Create free account
hub / github.com/atomicdotdev/atomic / test_truncate_prompt_long

Function test_truncate_prompt_long

atomic-agent/src/record/tests.rs:55–60  ·  view source on GitHub ↗
()

Source from the content-addressed store, hash-verified

53
54#[test]
55fn test_truncate_prompt_long() {
56 let s = "a".repeat(100);
57 let result = truncate_prompt(&s, 72);
58 assert!(result.len() <= 72);
59 assert!(result.ends_with("..."));
60}
61
62#[test]
63fn test_truncate_prompt_trims_whitespace() {

Callers

nothing calls this directly

Calls 1

truncate_promptFunction · 0.70

Tested by

no test coverage detected