Skip to content

Commit

Permalink
[ci-visibility] Use system's node instead of the bundled one in cypre…
Browse files Browse the repository at this point in the history
…ss tests (#4011)
  • Loading branch information
juan-fernandez authored and tlhunter committed Feb 14, 2024
1 parent f76c09b commit fa4dd76
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 1 deletion.
3 changes: 3 additions & 0 deletions .github/workflows/project.yml
Original file line number Diff line number Diff line change
Expand Up @@ -53,6 +53,9 @@ jobs:
integration-cypress:
strategy:
matrix:
# Important: This is outside the minimum supported version of dd-trace-js
# Node > 16 does not work with Cypress@6.7.0 (not even without our plugin)
# TODO: figure out what to do with this: we might have to deprecate support for cypress@6.7.0
version: [16, latest]
# 6.7.0 is the minimum version we support
cypress-version: [6.7.0, latest]
Expand Down
3 changes: 2 additions & 1 deletion integration-tests/cypress-config.json
Original file line number Diff line number Diff line change
Expand Up @@ -4,5 +4,6 @@
"pluginsFile": "cypress/plugins-old/index.js",
"supportFile": "cypress/support/e2e.js",
"integrationFolder": "cypress/e2e",
"defaultCommandTimeout": 100
"defaultCommandTimeout": 100,
"nodeVersion": "system"
}
4 changes: 4 additions & 0 deletions integration-tests/cypress/cypress.spec.js
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ const {
} = require('../../packages/dd-trace/src/plugins/util/test')
const { ERROR_MESSAGE } = require('../../packages/dd-trace/src/constants')
const semver = require('semver')
const { NODE_MAJOR } = require('../../version')

const version = process.env.CYPRESS_VERSION
const hookFile = 'dd-trace/loader-hook.mjs'
Expand All @@ -56,6 +57,9 @@ moduleType.forEach(({
if (type === 'esm' && semver.satisfies(version, '<10.0.0')) {
return
}
if (version === '6.7.0' && NODE_MAJOR > 16) {
return
}
describe(`cypress@${version} ${type}`, function () {
this.retries(2)
this.timeout(60000)
Expand Down

0 comments on commit fa4dd76

Please sign in to comment.