Commit Graph

5 Commits

Author SHA1 Message Date
david b3907d046d test: update Cucumber configuration and support files 2026-04-26 16:39:14 -07:00
david 73f5905990 fix: add browser relaunch logic to Cucumber hooks
- Add error handling for browser context creation
- Auto-relaunch browser if context creation fails
- Add better error logging
2026-04-26 16:39:14 -07:00
david 5519ed1de0 fix: add database safety check to Cucumber hooks
- Prevents tests from running against production database
- Uses same logic as Playwright global setup
- Ensures test data isolation
2026-04-26 16:39:13 -07:00
david 933f2cf808 fix: update Cucumber config and hooks to properly load test infrastructure
- Add support files to require config for proper hook loading
- Remove database cleanup from hooks (browser-only testing)
- Fix World type issues in hooks
- Cucumber tests now run successfully
2026-04-26 16:39:13 -07:00
david 496541b144 feat: add cucumber gherkin-style E2E test framework
- Install @cucumber/cucumber and cucumber-pretty dependencies
- Create Cucumber configuration with tsx loader for TypeScript support
- Add step definitions for common navigation, form interactions, and assertions
- Add authentication step definitions for login/logout flows
- Create feature files for user registration and authentication
- Support multiple auth contexts (player, tournament admin, club admin)
- Configure package.json scripts for running Cucumber tests

Key features:
- Gherkin syntax (Given/When/Then) for behavior-driven testing
- Browser-only interactions (no direct database access)
- Dev site testing (tests run against running dev server)
- Happy path focus for acceptance testing
- Integration with existing TypeScript project
2026-04-26 16:39:13 -07:00