Skip to content

Open-source Grok Bot alternative with a virtual machine that bots can use

test(usage): cover token counts that round up to a million

afinitus583bce57dcbd
diff --git a/src/lib/usage.test.ts b/src/lib/usage.test.ts
index e80b003f9f..d290b344ce 100644
--- a/src/lib/usage.test.ts
+++ b/src/lib/usage.test.ts
@@ -29,6 +29,7 @@ describe("usage formatting", () => {
expect(formatTokens(950)).toBe("950");
expect(formatTokens(12_400)).toBe("12.4k");
expect(formatTokens(120_000)).toBe("120k");
+ expect(formatTokens(999_500)).toBe("1M");
expect(formatTokens(2_300_000)).toBe("2.3M");
});