Skip to content

fix(recording): restore Playwright spec 03 to green against current stack#109

Merged
AquiGorka merged 1 commit into
mainfrom
fix/recording-playwright-specs
Jun 2, 2026
Merged

fix(recording): restore Playwright spec 03 to green against current stack#109
AquiGorka merged 1 commit into
mainfrom
fix/recording-playwright-specs

Conversation

@AquiGorka

Copy link
Copy Markdown
Contributor

Summary

Restores recording-rig spec 03 (Bob + Alice private transfer) end-to-end after the stack-wide moves landed since 2026-05-22. Specs 01, 02, 04 were already green on this branch's stack and are untouched. Just the rig changes — no application code in local-dev.

Depends on browser-wallet#20 and provider-platform#109 being deployed first.

What broke + how this fixes it

Pulled from the pairing thread's diagnose:

Layer Symptom Fix lives in
Channel-create against local stack Failed to fetch Quorum Contract ID (SIM_002) — wallet's service-worker fetch to http://localhost:8000/soroban/rpc blocked by extension_pages CSP added in browser-wallet#18 browser-wallet#19 (already merged)
Bundle submission 404 /api/v1/bundle — provider-platform#106 moved bundle endpoints under /api/v1/providers/:ppPublicKey/entity/bundles browser-wallet#20
Bundle submission 403 Submitter not approved (BND_011) — wallet had no surface for KYC submission browser-wallet#20 + provider-platform#109 (entityStatus on SEP-10 verify)
Spec 03 itself env.PP_PK is the operator pubkey, not the PP's own pubkey that goes in the URL path this PR
Spec 03 itself Wallet form needs the PP pubkey; KYC prompt lives inside the channel-picker sheet, which closes after Approve this PR

Spec / fixture changes

  • specs/03-private-transfer.spec.ts: discover the PP's pubkey from council-platform's /api/v1/public/providers?councilId=… (label match on getProviderName()), and feed it + a per-wallet KYC entity name into addAndConnectProvider.
  • fixtures/browser-wallet.ts (addAndConnectProvider):
    • Fill the new #provider-pubkey input added in browser-wallet#20.
    • After sign-Approve, re-open the channel-picker sheet (the popup goes back to home with the sheet closed).
    • If the wallet renders the "Submit KYC" prompt (entityStatus != APPROVED), click it, fill name + password, submit.
    • Press Escape to close the sheet so the home Receive/Send/Ramp buttons aren't covered by the overlay.

No other beats changed. The original showReceive / deposit / send / withdraw / toggleToPublicView flow is untouched.

Verification

Local stack: 3 councils × 12 PPs (post-#101 setup) + spec-02's Provider Helios, on provider-platform@feat/sep10-verify-returns-entity-status (0.7.0) + browser-wallet@feat/per-pp-urls-and-kyc-step.

  • 01-council-onboard: PASS (2.4 min)
  • 02-provider-create-join-approve: PASS (3.2 min)
  • 03-private-transfer: PASS (5.4 min) — full Bob→Alice flow, withdraw, closing public-balance beat
  • 04-dashboard-tour: PASS (24 s)

Out of scope (follow-up)

  • A second-look refactor of the wallet's UX so KYC is also surfaced at the home level (not only inside the sheet) — current placement matches where the provider row lives, but a top-level banner would prevent the recording-rig sheet dance.
  • Public PP-discovery endpoint on provider-platform so the wallet doesn't need the operator to paste the PP pubkey manually.

Test plan

  • All 4 specs green individually on the matched stack
  • Full-suite RUN_ID=… npm run record end-to-end after browser-wallet#20 + provider-platform#109 merge

Two changes inside the recording rig — no new behaviour beyond
restoring the previously-green path:

1. spec 03 now discovers the PP's stellar public key via
   council-platform's public listing (`/api/v1/public/providers?
   councilId=…`, label match) instead of passing `env.PP_PK` (the PP
   operator's pubkey, not the PP itself). The per-PP URL paths added
   by provider-platform#106 need the PP's own key.

2. `addAndConnectProvider` now (a) fills the new `Provider Public Key`
   input added in browser-wallet#20, (b) re-opens the channel picker
   sheet after Approve, completes the KYC form if the wallet surfaces
   the "Submit KYC" prompt (entityStatus != APPROVED), and (c) closes
   the sheet with Escape so the home view's Receive/Send/Ramp aren't
   blocked by the overlay.

Specs 01, 02, 04 were verified untouched-green against the same
patched stack. Spec 03 reached green end-to-end in 5.4 min including
Bob's withdraw and the public-balance closing beat.

Requires browser-wallet#20 and provider-platform#109 deployed first.
@AquiGorka
AquiGorka merged commit fd7c04b into main Jun 2, 2026
7 checks passed
@AquiGorka
AquiGorka deleted the fix/recording-playwright-specs branch June 2, 2026 19:44
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant