Verify #389: fix SEC-A02 wrap-swap E2E env loading and docs #921
No reviewers
Labels
No labels
agent:fix_bugfix
agent:fix_conflicts
agent:fix_security
agent:gap_analysis
agent:implement
agent:implement
agent:implement
agent:open_issues
agent:ready
agent:research
agent:security_audit
agent:verify
architecture
backend
blocker:hybrid
blocker:launch
blocker:limit-orders
blocker:v2
block:log_only
block:security
bug
ci
contracts
correctness
deploy
dev
devops
docs
documentation
duplicate
e2e
enhancement
epic
feature
frontend
functional-completion
gas
good first issue
governance
help wanted
high-risk
hooks
hybrid
indexer
infra
infrastructure
integrators
invalid
launch-blocker
limit-orders
localnet
localterra
low priority
missing-implementation
needs-design
ops
performance
priority
high
priority
medium
product
qa
QA
question
ready
ready
research
scripts
security
security-hardening
smartcontracts
tech-debt
testing
ux
UX
v2
verification
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
code/cl8y-dex-terraclassic!921
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "verify-issue-389-e2e-env-fix"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Summary
Verification of GitLab #389 found the merged SEC-A02 tests and copy were correct in code, but E2E verification could not run because:
wrapMapperAddressFromEnv()only readprocess.env.VITE_WRAP_MAPPER_ADDRESS, which Playwright does not populate fromfrontend-dapp/.env.local.--project=e2e-smoke, butwrap-swap.spec.tsis intxSpecGlobs(only runs undere2e-tx).This MR loads the wrap-mapper address from deploy output in global setup and as a
.env.localfallback in the LCD mock helper, and corrects verification commands.Acceptance checklist (#389)
SwapPage.test.tsx+ Playwrightwrap mapper pausedspecexpect(btn).toBeDisabled()in bothexpect(btn).toBeDisabled()in bothitblocks / specs; no combined regexCommands run
Security review — MR !921
Commit reviewed:
7cd9c41b3bbcc4e8cd6741ddb7ae0679a2515747Scope: E2E test env loading (
wrap-mapper-lcd-mock.ts,global-setup.ts) and verification docs (docs/testing.md,e2e/README.md,skills/AGENTS_FRONTEND_SWAP_SAFETY_CTA.md).Outcome:
FINDINGS: 0medium+Summary: No medium, high, or critical vulnerabilities introduced or exposed by this diff.
Reviewed paths:
wrapMapperAddressFromEnv()fallback read offrontend-dapp/.env.local— E2E-only helper; path is derived from fixedimport.meta.urlrelatives (no attacker-controlled traversal); value is validated withstartsWith('terra1')before use; mirrors existingapplyViteEnvFromEnvLocal()inglobal-setup.ts.global-setup.tsaddition ofVITE_WRAP_MAPPER_ADDRESS— same line-parse pattern as existing LCD/indexer/token vars; runs only in Playwright global setup (dev/CI), not in production bundles.e2e-smoke→e2e-tx) — no runtime security impact.No production application code, auth boundaries, on-chain logic, or user-facing input handling changed. Contract addresses in
.env.localare public deploy artifacts, not secrets.Inline threads: none (no findings to anchor).
Security review: no medium+ findings on this diff.
mentioned in commit
4b0e10401f