Stabilize flaky SDK multicall tests with recorded keeper fixtures FEDEV-4029#2623
Open
qwinndev wants to merge 1 commit into
Open
Stabilize flaky SDK multicall tests with recorded keeper fixtures FEDEV-4029#2623qwinndev wants to merge 1 commit into
qwinndev wants to merge 1 commit into
Conversation
Alias cross-fetch in the multicall vitest run to a mock that serves recorded gmxinfra keeper responses (markets/tokens/tickers) instead of flaky live network calls, and un-skip the six v1 integration suites. RPC multicalls and subsquid stay live. FEDEV-4029
Deploying gmx-interface-home with
|
| Latest commit: |
2a4c50e
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://ce918294.gmx-interface-home.pages.dev |
| Branch Preview URL: | https://mock-sdk-multicall-fedev-402.gmx-interface-home.pages.dev |
Deploying gmx-interface with
|
| Latest commit: |
2a4c50e
|
| Status: | ✅ Deploy successful! |
| Preview URL: | https://7e18e6e9.gmx-interface.pages.dev |
| Branch Preview URL: | https://mock-sdk-multicall-fedev-402.gmx-interface.pages.dev |
Playwright Component Test ReportAll tests passed. Commit 2a4c50e |
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.
Problem
The
Run SDK multicall testsCI step (cd sdk && yarn test:multicall) runs six v1 integration specs that fetched the live gmxinfra keeper (/markets,/tokens,/prices/tickers). These calls intermittently failed withFetchError: ... Premature close, reddening CI even with no code change. As a stop-gap the suites weredescribe.skipped.Fix
Alias
cross-fetchinsdk/vitest.multicall.config.tsto a mock (sdk/src/test/mockCrossFetch.ts) that serves recorded keeper responses fromsdk/src/test/fixtures/arbitrum{Markets,Tokens,Tickers}.jsonfor any*.gmxinfra.io/gmxinfra2.iohost, and rejects unrecorded keeper paths loudly. Every other host passes through to the realfetch.Re-record fixtures when needed with e.g.
curl https://arbitrum-api.gmxinfra.io/markets -o sdk/src/test/fixtures/arbitrumMarkets.json.Verified
yarn test:multicallgreen across 10 consecutive runs, with no live gmxinfra call.https://linear.app/gmx-io/issue/FEDEV-4029/stabilize-flaky-sdk-multicall-tests-live-network-fetcherror-in-ci