Standardize ellipsis to … in snippet truncation

This commit is contained in:
Ivan Pereira
2026-02-23 10:49:43 +00:00
parent 909145de94
commit 56ef5533a3
2 changed files with 2 additions and 2 deletions
+1 -1
View File
@@ -8,7 +8,7 @@ function truncateSnippet(snippet: string): string {
return normalized;
}
return `${normalized.slice(0, MAX_SNIPPET_LENGTH - 3)}...`;
return `${normalized.slice(0, MAX_SNIPPET_LENGTH - 1)}`;
}
function humanizeAge(timestamp?: string): string {
+1 -1
View File
@@ -98,7 +98,7 @@ describe("formatForLLM", () => {
const snippetLine = output
.split("\n")
.find((line) => line.startsWith(" ") && line.includes("..."));
.find((line) => line.startsWith(" ") && line.includes(""));
expect(snippetLine).toBeDefined();
expect(snippetLine!.trim().length).toBe(240);