We have Playwright e2e coverage for the bounty application flow in e2e/bounty-application.spec.ts, but the bounty creation flow at /bounty/create has no e2e coverage. This is the highest-value path on the sponsor side and we keep changing the form fields without a regression net.
What to do
Add e2e/bounty-creation.spec.ts covering:
- Navigation to
/bounty/create while authenticated (use the same MOCK_SESSION pattern from the existing spec)
- Step 1: fill title, description, organization, GitHub URL, and bounty type
- Step 2: fill reward amount, currency, and deadline (and the milestone or competition fields if the type requires them)
- Step 3: review and click Create
- Assert the user is redirected to
/bounty/{newId} after successful creation
- A separate test for the validation path: submitting Step 1 with an empty title should keep the user on Step 1 and show the title error
Mock the CreateBounty GraphQL mutation via page.route('**/api/graphql', ...) following the same setup pattern as bounty-application.spec.ts.
Acceptance criteria
- Happy-path test passes locally and on CI
- Validation test passes locally and on CI
pnpm exec playwright test e2e/bounty-creation.spec.ts green
- New tests follow the structure and mock conventions in
bounty-application.spec.ts
Files
e2e/bounty-creation.spec.ts (new)
We have Playwright e2e coverage for the bounty application flow in
e2e/bounty-application.spec.ts, but the bounty creation flow at/bounty/createhas no e2e coverage. This is the highest-value path on the sponsor side and we keep changing the form fields without a regression net.What to do
Add
e2e/bounty-creation.spec.tscovering:/bounty/createwhile authenticated (use the sameMOCK_SESSIONpattern from the existing spec)/bounty/{newId}after successful creationMock the
CreateBountyGraphQL mutation viapage.route('**/api/graphql', ...)following the same setup pattern asbounty-application.spec.ts.Acceptance criteria
pnpm exec playwright test e2e/bounty-creation.spec.tsgreenbounty-application.spec.tsFiles
e2e/bounty-creation.spec.ts(new)