Conversation
WalkthroughThis update enhances Playwright-based end-to-end testing for the deploy-web application. It adjusts test timeouts, adds runtime logging, improves wallet funding logic, updates environment configuration, and modifies Playwright and GitHub Actions setup. Several fixtures and helper functions are revised for reliability and maintainability, with no changes to exported API signatures. Changes
Sequence Diagram(s)sequenceDiagram
participant TestRunner as Playwright Test
participant Wallet as Wallet Extension
participant Faucet as Faucet API
participant Blockchain as Chain API
TestRunner->>Wallet: Open extension, connect wallet
TestRunner->>Blockchain: getBalance(address)
Blockchain-->>TestRunner: Return balance
alt Balance > 100 AKT
TestRunner->>TestRunner: Skip faucet top-up
else Balance <= 100 AKT
TestRunner->>Faucet: Request funds (FAUCET_URL)
Faucet-->>TestRunner: Faucet response
end
TestRunner->>TestRunner: Proceed with deployment test
TestRunner->>TestRunner: Log progress at key steps
TestRunner->>Wallet: Sign transaction
Wallet-->>TestRunner: Transaction signed
TestRunner->>TestRunner: Wait for "Transaction success"
Suggested reviewers
Poem
Warning There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure. 🔧 ESLint
npm error Exit handler never called! 📜 Recent review detailsConfiguration used: CodeRabbit UI ⛔ Files ignored due to path filters (1)
📒 Files selected for processing (11)
✅ Files skipped from review due to trivial changes (1)
🚧 Files skipped from review as they are similar to previous changes (8)
🧰 Additional context used🪛 Biome (1.9.4)apps/deploy-web/tests/fixture/context-with-extension.ts[error] 22-22: Unexpected empty object pattern. (lint/correctness/noEmptyPattern) ⏰ Context from checks skipped due to timeout of 90000ms (1)
🔇 Additional comments (2)
✨ Finishing Touches
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. 🪧 TipsChatThere are 3 ways to chat with CodeRabbit:
SupportNeed help? Create a ticket on our support page for assistance with any issues or questions. Note: Be mindful of the bot's finite context window. It's strongly recommended to break down tasks such as reading entire modules into smaller chunks. For a focused discussion, use review comments to chat about specific files and their changes, instead of using the PR comments. CodeRabbit Commands (Invoked using PR comments)
Other keywords and placeholders
CodeRabbit Configuration File (
|
b593dee to
844f81a
Compare
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #1401 +/- ##
==========================================
- Coverage 36.39% 36.39% -0.01%
==========================================
Files 818 818
Lines 19681 19681
Branches 3642 3643 +1
==========================================
- Hits 7163 7162 -1
+ Misses 12343 11949 -394
- Partials 175 570 +395
*This pull request uses carry forward flags. Click here to find out more. 🚀 New features to boost your workflow:
|
There was a problem hiding this comment.
Actionable comments posted: 1
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
📒 Files selected for processing (5)
.github/actions/console-web-ui-testing/action.yml(1 hunks).github/workflows/console-web-docker-build.yml(1 hunks)apps/deploy-web/playwright.config.ts(2 hunks)apps/deploy-web/tests/deploy-hello-world.spec.ts(1 hunks)apps/deploy-web/tests/fixture/context-with-extension.ts(3 hunks)
🚧 Files skipped from review as they are similar to previous changes (4)
- apps/deploy-web/playwright.config.ts
- apps/deploy-web/tests/deploy-hello-world.spec.ts
- apps/deploy-web/tests/fixture/context-with-extension.ts
- .github/workflows/console-web-docker-build.yml
⏰ Context from checks skipped due to timeout of 90000ms (2)
- GitHub Check: test-deploy-web-build
- GitHub Check: test-beta
There was a problem hiding this comment.
Actionable comments posted: 0
🧹 Nitpick comments (1)
apps/deploy-web/tests/fixture/context-with-extension.ts (1)
21-22: Remove unnecessary empty object pattern.The empty object pattern is unnecessary when no parameters are being destructured. This aligns with the static analysis hint.
- // eslint-disable-next-line no-empty-pattern - context: async ({}, use) => { + context: async (_, use) => {🧰 Tools
🪛 Biome (1.9.4)
[error] 22-22: Unexpected empty object pattern.
(lint/correctness/noEmptyPattern)
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
⛔ Files ignored due to path filters (1)
package-lock.jsonis excluded by!**/package-lock.json
📒 Files selected for processing (6)
.github/actions/console-web-ui-testing/action.yml(1 hunks).github/workflows/console-web-docker-build.yml(1 hunks)apps/deploy-web/package.json(1 hunks)apps/deploy-web/playwright.config.ts(2 hunks)apps/deploy-web/tests/deploy-hello-world.spec.ts(1 hunks)apps/deploy-web/tests/fixture/context-with-extension.ts(3 hunks)
✅ Files skipped from review due to trivial changes (1)
- apps/deploy-web/package.json
🚧 Files skipped from review as they are similar to previous changes (4)
- .github/actions/console-web-ui-testing/action.yml
- apps/deploy-web/tests/deploy-hello-world.spec.ts
- apps/deploy-web/playwright.config.ts
- .github/workflows/console-web-docker-build.yml
🧰 Additional context used
🪛 Biome (1.9.4)
apps/deploy-web/tests/fixture/context-with-extension.ts
[error] 22-22: Unexpected empty object pattern.
(lint/correctness/noEmptyPattern)
⏰ Context from checks skipped due to timeout of 90000ms (2)
- GitHub Check: test-beta
- GitHub Check: test-deploy-web-build
🔇 Additional comments (2)
apps/deploy-web/tests/fixture/context-with-extension.ts (2)
32-34: Good addition of CI-specific GPU flags for browser compatibility.Adding GPU-related Chrome flags when running in CI environment is a solid approach to handle headless browser rendering issues that commonly occur in CI environments. These flags help ensure consistent test execution by using software rendering instead of hardware acceleration.
71-71: Excellent addition of explicit page cleanup.Explicitly closing the extension page is a good practice for proper resource cleanup and preventing potential memory leaks in test environments, especially important for long-running test suites.
There was a problem hiding this comment.
Actionable comments posted: 1
🧹 Nitpick comments (1)
apps/deploy-web/tests/fixture/context-with-extension.ts (1)
32-34: Consider uncommenting GPU flags for CI stability.The commented GPU flags might be important for Chrome stability in headless CI environments. These flags are commonly used to resolve rendering issues in containerized environments.
Consider uncommenting and testing these flags:
if (process.env.CI) { - // args.push("--ignore-gpu-blocklist", "--use-gl=angle", "--use-angle=gl-egl"); + args.push("--ignore-gpu-blocklist", "--use-gl=angle", "--use-angle=gl-egl"); }If these flags cause issues, you might also consider adding
--disable-gpuas an alternative for CI environments.
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
⛔ Files ignored due to path filters (1)
package-lock.jsonis excluded by!**/package-lock.json
📒 Files selected for processing (6)
.github/actions/console-web-ui-testing/action.yml(1 hunks).github/workflows/console-web-docker-build.yml(1 hunks)apps/deploy-web/package.json(1 hunks)apps/deploy-web/playwright.config.ts(2 hunks)apps/deploy-web/tests/deploy-hello-world.spec.ts(1 hunks)apps/deploy-web/tests/fixture/context-with-extension.ts(3 hunks)
🚧 Files skipped from review as they are similar to previous changes (5)
- apps/deploy-web/tests/deploy-hello-world.spec.ts
- .github/actions/console-web-ui-testing/action.yml
- apps/deploy-web/package.json
- apps/deploy-web/playwright.config.ts
- .github/workflows/console-web-docker-build.yml
🧰 Additional context used
🪛 Biome (1.9.4)
apps/deploy-web/tests/fixture/context-with-extension.ts
[error] 22-22: Unexpected empty object pattern.
(lint/correctness/noEmptyPattern)
⏰ Context from checks skipped due to timeout of 90000ms (2)
- GitHub Check: test-deploy-web-build
- GitHub Check: test-beta
🔇 Additional comments (1)
apps/deploy-web/tests/fixture/context-with-extension.ts (1)
71-71: Good addition of explicit cleanup.Adding explicit page cleanup is a good practice for resource management and preventing potential memory leaks in test environments.
e156c04 to
728ce4f
Compare
There was a problem hiding this comment.
Actionable comments posted: 1
♻️ Duplicate comments (1)
apps/deploy-web/tests/fixture/context-with-extension.ts (1)
21-22: Fix the empty object pattern flagged by static analysis.The empty object pattern
{}is flagged by the linter and should be addressed as previously noted.Consider using one of the suggested approaches from the previous review:
- Use
async (_, use) =>if no parameters are needed- Use
async ({ }, use) =>with a space for clarity🧰 Tools
🪛 Biome (1.9.4)
[error] 22-22: Unexpected empty object pattern.
(lint/correctness/noEmptyPattern)
📜 Review details
Configuration used: CodeRabbit UI
Review profile: CHILL
Plan: Pro
⛔ Files ignored due to path filters (1)
package-lock.jsonis excluded by!**/package-lock.json
📒 Files selected for processing (8)
.github/actions/console-web-ui-testing/action.yml(1 hunks).github/workflows/console-web-docker-build.yml(1 hunks)apps/deploy-web/package.json(1 hunks)apps/deploy-web/playwright.config.ts(2 hunks)apps/deploy-web/tests/deploy-hello-world.spec.ts(1 hunks)apps/deploy-web/tests/fixture/context-with-extension.ts(3 hunks)apps/deploy-web/tests/fixture/wallet-setup.ts(2 hunks)apps/deploy-web/tests/uiState/isWalletConnected.ts(1 hunks)
🚧 Files skipped from review as they are similar to previous changes (6)
- .github/actions/console-web-ui-testing/action.yml
- apps/deploy-web/playwright.config.ts
- apps/deploy-web/package.json
- apps/deploy-web/tests/uiState/isWalletConnected.ts
- apps/deploy-web/tests/deploy-hello-world.spec.ts
- .github/workflows/console-web-docker-build.yml
🧰 Additional context used
🧬 Code Graph Analysis (1)
apps/deploy-web/tests/fixture/wallet-setup.ts (1)
apps/deploy-web/src/utils/apiUtils.ts (1)
balance(45-47)
🪛 Biome (1.9.4)
apps/deploy-web/tests/fixture/context-with-extension.ts
[error] 22-22: Unexpected empty object pattern.
(lint/correctness/noEmptyPattern)
⏰ Context from checks skipped due to timeout of 90000ms (2)
- GitHub Check: test-deploy-web-build
- GitHub Check: test-beta
🔇 Additional comments (2)
apps/deploy-web/tests/fixture/context-with-extension.ts (1)
67-67: Good cleanup practice!Adding explicit cleanup with
await extPage.close()ensures proper resource management and prevents potential memory leaks in test runs.apps/deploy-web/tests/fixture/wallet-setup.ts (1)
99-104: Good optimization to avoid unnecessary faucet requests.The balance check logic is sound and will help reduce load on the faucet service by skipping requests when the wallet already has sufficient funds (10 uakt threshold).
06f0d1e to
c096c4b
Compare
Why
broken tests
What
Summary by CodeRabbit
New Features
Improvements
Bug Fixes
Chores