Skip to content

Fix gateway integration test pollution from .env.local - #80

Merged
crtahlin merged 1 commit into
mainfrom
fix/gateway-test-pollution
Mar 2, 2026
Merged

Fix gateway integration test pollution from .env.local#80
crtahlin merged 1 commit into
mainfrom
fix/gateway-test-pollution

Conversation

@crtahlin

@crtahlin crtahlin commented Mar 2, 2026

Copy link
Copy Markdown

Summary

  • The gateway_url fixture in integration tests was reading PROVENANCE_GATEWAY_URL, which .env.local overrides to localhost:8000 for local development
  • This caused 4 gateway tests to fail when run with .env.local sourced (needed for x402/chain tests)
  • Changed fixture to use INTEGRATION_GATEWAY_URL env var, defaulting to production gateway, keeping integration tests independent of app config

Test plan

  • All 35 integration tests pass (gateway, x402, Hardhat, Base Sepolia)
  • 545 unit tests pass
  • Gateway tests pass both with and without .env.local sourced

The gateway_url fixture was reading PROVENANCE_GATEWAY_URL, which
.env.local overrides to localhost:8000 for local development. This
caused gateway tests to fail when run with .env.local sourced.

Use a separate INTEGRATION_GATEWAY_URL env var so integration tests
always default to the production gateway independently of app config.
@crtahlin
crtahlin merged commit 1943fe3 into main Mar 2, 2026
11 checks passed
@crtahlin
crtahlin deleted the fix/gateway-test-pollution branch March 2, 2026 20:50
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