[Spike] Assess verification against real wallet versions #118 - #130
Open
EmmanuelAdah wants to merge 17 commits into
Open
[Spike] Assess verification against real wallet versions #118#130EmmanuelAdah wants to merge 17 commits into
EmmanuelAdah wants to merge 17 commits into
Conversation
…tion, and improved decision handling.
…ge exclude paths.
…and Albedo, replace outdated POC coverage report, and adjust diagnostics parsing.
…hter, update Playwright config for real-wallet tests, and add wallet contract validation tests.
…optimize Playwright install process
…ghter and Albedo releases, including testing strategy recommendations, compatibility matrix, and protocol contract schema PoC.
… to v1.18.0, and `bignumber.js` to v11.1.4.
…est/coverage-v8` to v4.1.11, and `vite` to v8.2.2; remove outdated and unused packages.
Contributor
|
please pass failing test |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Closes #131
PR 1: Add protocol-drift detection infrastructure for real Freighter/Albedo wallet testing
📝 Summary
This PR adds a spike report and initial infrastructure for detecting when real Freighter/Albedo extension releases drift from what Gryd Lock's synthetic end-to-end (e2e) fixtures assume. It splits CI into fast/blocking checks versus slower/non-blocking real-wallet canary checks, and introduces a first real-wallet interception test against a live Freighter build.
📦 What's Included
Docs: protocol-drift-spike.md contains synthetic coverage analysis, a wallet compatibility matrix template, protocol-fixture proposals, CI/scheduled recommendations, and a follow-up plan.
External Protocol Contracts: src/intercept/externalWalletProtocol.ts includes zod schemas and type guards for Freighter's SUBMIT_TRANSACTION request/response and Albedo's intent request/response. Note: Only the decline/reject path is confirmed against real fixtures for both wallets. Success-response shapes are currently unconfirmed.
Real-Wallet e2e: e2e/real/real-freighter-version.spec.ts loads a version-pinned Freighter build to capture and validate real extension messages. Additional config files (playwright.canary.config.ts, playwright.e2e.config.ts) isolate these tests from the default e2e suite.
Scripts: scripts/download-wallet-release.sh fetches pinned wallet tags, and tests/wallet-versions.json acts as the single source of truth for versions.
CI Updates: Added npm audit checks and version-checking to the PR-blocking path (ci.yml). Introduced a scheduled, non-blocking workflow (wallet-canary.yml) that opens a GitHub issue on failure.
Misc: Fixed .gitignore pathing for fixtures/wallets/**/ and added standard ignores like coverage/ and .env*.
Build Scripts: scripts/download-wallet-release.sh only clones the source; it does not build it yet.
Test Failures: The real Freighter test fails on a fresh profile because it lacks an onboarded account. Selectors in e2e/real/helpers/onboardFreighter.ts are placeholders and require a recorded session to pass.
Missing Documentation: No golden-capture fixtures or docs/wallet-compatibility.md populated yet.
Missing Packaging: No packaging/zip step implementing releaseArchiveName().
🧪 Testing
Run Canary: npx playwright test --config=playwright.canary.config.ts -g "Real-wallet protocol drift: Freighter" (Fails at the onboarding gap as expected).
Existing Suites: Synthetic suite (npm run test:e2e) and contract tests (npm run test:all) are completely unaffected.
⏭️ Follow-ups (Not in this PR)