Session Consistency
Test #19Can your scraper log in once and return later without re-authenticating? This test verifies cross-session cookie persistence — just like a real browser that stays logged in.
Test Passing Criteria
How It Works
Real users log in once and stay logged in for days or weeks. Their browser persists cookies across tabs, restarts, and separate browsing sessions. This test checks whether your scraper can do the same.
Phase 1 — First Visit (Login & Scrape):
- Login via POST to
/api/test/session-consistency/loginwith test credentials - Access profile at
/api/test/session-consistency/profileto get authenticated data - Visit step pages (steps 2-4) to scrape content
- Save all cookies from your cookie jar to disk
Phase 2 — Return Visit (No Login):
- Load saved cookies into your scraper
- Go directly to
/api/test/session-consistency/returning— do NOT login again - If your cookies are valid, exclusive returning-visitor data is unlocked
Two-Phase Flow
Phase 1 — First Visit
Save cookies to disk
Phase 2 — Return Visit
Check
GET /api/test/session-consistency/checkReturn
GET /api/test/session-consistency/returningTest Credentials
Username: testuser1 through testuser5
Password: password123