test: split user lookup coverage

This commit is contained in:
Peter Steinberger
2026-01-12 02:09:52 +00:00
parent 436d4dfb89
commit 9dd9efa4e3
3 changed files with 168 additions and 157 deletions
+2 -1
View File
@@ -281,7 +281,8 @@ d('live CLI (Twitter/X)', () => {
const tweets = parseJson<Array<{ id?: string; author?: { username?: string } }>>(userTweets.stdout);
expect(Array.isArray(tweets)).toBe(true);
expect(tweets.length).toBeGreaterThan(0);
expect(tweets[0].author?.username?.toLowerCase()).toBe(testHandle.toLowerCase());
const handleLower = testHandle.toLowerCase();
expect(tweets.some((t) => t.author?.username?.toLowerCase() === handleLower)).toBe(true);
});
it('user-tweets paged JSON returns { tweets, nextCursor }', async () => {