Fix ArtifactEngine CI test failures by updating nock to v14#1352
Draft
v-abhishera wants to merge 1 commit intomasterfrom
Draft
Fix ArtifactEngine CI test failures by updating nock to v14#1352v-abhishera wants to merge 1 commit intomasterfrom
v-abhishera wants to merge 1 commit intomasterfrom
Conversation
|
Azure Pipelines: Successfully started running 1 pipeline(s). |
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.
Description:
Summary
The ArtifactEngine integration tests fail in CI due to
nock@9.1.0being incompatible with Node 24's stricter stream type checking. This PR updates nock to v14 and fixes related test issues.Root Cause
The CI pipeline (azure-pipelines-extensions.yml) runs tests on Node 24.
nock@9.1.0uses internal stream APIs that changed in Node 24, causingTypeErrorcrashes in all nock-based integration tests.Changes
1. Update nock dependency (package.json)
nock:9.1.0→^14.0.62. Fix jenkins integration tests (jenkinsTests.ts)
nock.disableNetConnect()andnock.enableNetConnect('127.0.0.1')inbeforeEach— required by nock v14 to properly intercept HTTP requests.3. Fix proxy integration tests (proxyTests.ts)
redvstt-lab43:8080with127.0.0.1:9011(the test's own local server) — the old hostname was a decommissioned dev machine.new Buffer()withBuffer.from()—Buffer()constructor is removed in newer Node versions.Testing
npx gulp test --suite=ArtifactEngine).Files Changed
9.1.0→^14.0.6nock.disableNetConnect()/enableNetConnect()new Buffer()Risk Assessment
Low — Only test infrastructure changes; no production code affected.