Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore: test ethers verify API + AppKit in iframe verify test case #2831

Merged
merged 17 commits into from
Nov 21, 2024

Conversation

chris13524
Copy link
Member

@chris13524 chris13524 commented Sep 10, 2024

Description

Adds missing test coverage for Verify API on the Ethers SDK.

Also adds test coverage for https://github.com/WalletConnect/cloud-app/pull/1509

Remaining work:

Fixes APKT-1445

Type of change

  • Chore (non-breaking change that addresses non-functional tasks, maintenance, or code quality improvements)

@chris13524 chris13524 self-assigned this Sep 10, 2024
Copy link

vercel bot commented Sep 10, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Comments Updated (UTC)
appkit-gallery-new ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 21, 2024 5:24pm
appkit-laboratory ✅ Ready (Inspect) Visit Preview Nov 21, 2024 5:24pm
appkit-vue-solana ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 21, 2024 5:24pm
appkit-wagmi-cdn-example ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 21, 2024 5:24pm
vue-wagmi-example ✅ Ready (Inspect) Visit Preview 💬 Add feedback Nov 21, 2024 5:24pm
web3modal-gallery ✅ Ready (Inspect) Visit Preview Nov 21, 2024 5:24pm
web3modal-laboratory ✅ Ready (Inspect) Visit Preview Nov 21, 2024 5:24pm

Copy link
Contributor

github-actions bot commented Sep 10, 2024

Coverage Report for Coverage

Status Category Percentage Covered / Total
🔵 Lines 335.7% 4838 / 23584
🔵 Statements 335.7% 4838 / 23584
🔵 Functions 368.88% 388 / 1431
🔵 Branches 475.80999999999995% 745 / 1724
File CoverageNo changed files found.
Generated in workflow #7526 for commit 9ea67a6 by the Vitest Coverage Report Action

Copy link
Contributor

github-actions bot commented Sep 10, 2024

♻️ Vite-Size ♻️

Size Difference

Size (kb) Gzip (kb)
Total Diff. 0 0

Current Size

Name Size (kb) Gzip (kb)
assets/index-ClB9DH0L.js 1602.086 464.674
assets/noble-curves.js 31.941 12.782
assets/2.19.6_bufferutil.js 2.789 1.328
assets/index.js 9.516 3.191
assets/index2.js 102.248 29.113
assets/index3.js 304.387 87.28
assets/walletconnect-ethereum-provider.js 438.506 138.106
assets/index4.js 11.601 3.206
assets/w3m-modal.js 6.988 2.506
assets/index5.js 12.673 4.695
assets/hooks.module.js 74.437 25.583
assets/walletconnect-modal-ui.js 112.43 34.326
index.html 0.329 0.238
Total Size 2709.931 807.028

Base Size

Name Size (kb) Gzip (kb)
assets/index-ClB9DH0L.js 1602.086 464.674
assets/noble-curves.js 31.941 12.782
assets/2.19.6_bufferutil.js 2.789 1.328
assets/index.js 9.516 3.191
assets/index2.js 102.248 29.113
assets/index3.js 304.387 87.28
assets/walletconnect-ethereum-provider.js 438.506 138.106
assets/index4.js 11.601 3.206
assets/w3m-modal.js 6.988 2.506
assets/index5.js 12.673 4.695
assets/hooks.module.js 74.437 25.583
assets/walletconnect-modal-ui.js 112.43 34.326
index.html 0.329 0.238
Total Size 2709.931 807.028

Copy link

changeset-bot bot commented Nov 12, 2024

⚠️ No Changeset found

Latest commit: 9ea67a6

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

This PR includes no changesets

When changesets are added to this PR, you'll see the packages that this PR includes changesets for and the associated semver types

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@chris13524 chris13524 changed the title chore: test ethers verify API chore: test ethers verify API + AppKit in iframe verify test case Nov 12, 2024
Copy link

linear bot commented Nov 12, 2024

Copy link
Contributor

github-actions bot commented Nov 12, 2024

Warnings
⚠️

Workflow file .github/workflows/ui_tests.yml has been modified

⚠️ Testing spec changed

Generated by 🚫 dangerJS against 9ea67a6

@@ -30,6 +30,18 @@ export const testM = timingFixture.extend<ModalFixture>({
await use(modalPage)
}
})
export const testMEthers = timingFixture.extend<ModalFixture>({
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

How is this different fromcthe default testM? / why does it need a special case?

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This should be refactored in the latest revision

object-src 'none';
base-uri 'self';
form-action 'self';
frame-ancestors 'none';
frame-ancestors ${verifyApiNestedIframesTestOuterDomain};
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

do we need to conditionally add this on test env?

Copy link
Member Author

@chris13524 chris13524 Nov 21, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

iirc adding it conditionally was tricky because the app is always built with NODE_ENV production, so it didn't know if it was building for tests or not

Didn't bother going deeper I don't think, so hardcoded an intentionally-long domain here which wouldn't be valid anyway

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.

2 participants