972 B
972 B
Testing
Unit tests (default)
pnpm test
Live tests (hits Twitter/X)
Runs the CLI against real Twitter/X GraphQL endpoints to verify read-only commands still work.
Requirements:
- Auth cookies in env:
AUTH_TOKEN(orTWITTER_AUTH_TOKEN)CT0(orTWITTER_CT0)
- Network access
Run:
pnpm test:live
Notes:
- Live tests are skipped unless
BIRD_LIVE=1(set bypnpm test:live). - Search query is configurable via
BIRD_LIVE_SEARCH_QUERY. - Command timeout is configurable via
BIRD_LIVE_TIMEOUT_MS(ms). - Cookie extraction timeout is configurable via
BIRD_LIVE_COOKIE_TIMEOUT_MS(ms). - Spawned CLI
NODE_ENVdefaults toproduction(override withBIRD_LIVE_NODE_ENV). - If you don't tweet, set
BIRD_LIVE_TWEET_IDto a known tweet ID to use forread/replies/thread. - Optional: set
BIRD_LIVE_BOOKMARK_FOLDER_IDto exercisebookmarks --folder-id. bird query-ids --freshlive coverage: setBIRD_LIVE_QUERY_IDS_FRESH=1.