Skip to content

Add end-to-end tests for mock and live-mode flows #17

@Lakes41

Description

@Lakes41

Summary

Add browser-level tests that verify the most important user journeys in mock mode and a controlled live-mode API fixture.

Current Behaviour

The repository does not include visible end-to-end tests. Important flows such as wallet connection state, dashboard rendering, access denial, admin navigation, member listing, and policy editing are not tested through a browser.

Expected Behaviour

Contributors should be able to run a deterministic E2E suite that validates critical flows before merging UI or API changes.

Suggested Implementation

Add Playwright and create wallet/API mocks for deterministic browser tests. Cover dashboard loading in mock mode, gated page allow/deny behaviour, admin member role assignment, policy editing, and live-mode error handling with intercepted network responses.

Files or Areas Likely Affected

  • package.json
  • playwright.config.ts
  • e2e/
  • lib/api/mock.ts
  • app/**/*.tsx
  • README.md
  • .github/workflows/

Acceptance Criteria

  • E2E tests run with npm run test:e2e
  • Tests cover mock mode without external services
  • Tests cover live-mode API success and failure using network fixtures
  • Tests verify gated content allow and deny states
  • Tests verify admin member and policy workflows
  • E2E setup is documented for contributors

Additional Notes

Avoid relying on a real browser wallet extension in CI. Use controlled mocks for wallet state.

Metadata

Metadata

Assignees

No one assigned

    Labels

    GrantFox OSSIssue tracked in GrantFox OSSMaybe RewardedIssue may be eligible for a GrantFox rewardOfficial CampaignCampaign: Official Campaign

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions