Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ci: fix errors in ci github action for node 8 and 9 #523

Merged
merged 6 commits into from
Jun 9, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
update query skip, actually skip, fix tracking issue link
  • Loading branch information
jonchurch committed Jun 9, 2024
commit b360292b1fca4d86488a49d6297f1e54ef494f05
15 changes: 7 additions & 8 deletions test/body-parser.js
Original file line number Diff line number Diff line change
Expand Up @@ -78,21 +78,20 @@ describe('bodyParser()', function () {
}

function shouldSkipQuery (versionString) {
// Temporarily skipping this test on 21
// update this implementation to run on those release lines on supported versions once they exist
// upstream tracking https://github.com/nodejs/node/pull/51719
// Skipping HTTP QUERY tests on Node 21, it is reported in http.METHODS on 21.7.2 but not supported
// update this implementation to run on supported versions of 21 once they exist
// upstream tracking https://github.com/nodejs/node/issues/51562
// express tracking issue: https://github.com/expressjs/express/issues/5615
var majorsToSkip = {
21: true
}
return majorsToSkip[getMajorVersion(versionString)]
return getMajorVersion(versionString) == 21
}

methods.slice().sort().forEach(function (method) {
if (method === 'connect') return
if (method === 'query' && shouldSkipQuery(process.versions.node)) return

it('should support ' + method.toUpperCase() + ' requests', function (done) {
if (method === 'query' && shouldSkipQuery(process.versions.node)) {
this.skip()
}
request(this.server)[method]('/')
.set('Content-Type', 'application/json')
.set('Content-Length', '15')
Expand Down
Loading