Skip to content

Commit c8e4338

Browse files
committed
test: add Node.js 10 to the CI test matrix (#314)
Until nodejs/node#20516 have been resolved, we have disabled the hapi tests to make sure we still test as much as possible on Node.js 10
1 parent 2e5cecb commit c8e4338

File tree

5 files changed

+31
-1
lines changed

5 files changed

+31
-1
lines changed

.travis.yml

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ before_script:
1919
- wait-on tcp:9200
2020

2121
node_js:
22+
- '10'
2223
- '9'
2324
- '8'
2425
- '6'
@@ -34,6 +35,9 @@ jobs:
3435
###########################################
3536

3637
# Disable Async Hooks
38+
-
39+
node_js: '10'
40+
env: ELASTIC_APM_ASYNC_HOOKS=0
3741
-
3842
node_js: '9'
3943
env: ELASTIC_APM_ASYNC_HOOKS=0
@@ -48,10 +52,12 @@ jobs:
4852

4953
# Commit Messages
5054
-
55+
node_js: 'lts/*'
5156
script: commitlint-travis
5257

5358
# Coverage
5459
-
60+
node_js: 'lts/*'
5561
script:
5662
- npm run coverage
5763
- ./node_modules/.bin/nyc report --reporter=lcov > coverage.lcov
@@ -62,6 +68,24 @@ jobs:
6268
# DEPENDENCY STAGE #
6369
###########################################
6470

71+
# Node.js 10
72+
- stage: dependencies
73+
node_js: '10'
74+
env: TAV=generic-pool,mysql,redis,koa-router,handlebars,mongodb-core
75+
script: 'if [[ "$TRAVIS_EVENT_TYPE" == "cron" || ("$TRAVIS_EVENT_TYPE" == "pull_request" && "$TRAVIS_BRANCH" != greenkeeper/*) ]]; then tav --quiet; fi'
76+
-
77+
node_js: '10'
78+
env: TAV=ioredis,pg
79+
script: 'if [[ "$TRAVIS_EVENT_TYPE" == "cron" || ("$TRAVIS_EVENT_TYPE" == "pull_request" && "$TRAVIS_BRANCH" != greenkeeper/*) ]]; then tav --quiet; fi'
80+
-
81+
node_js: '10'
82+
env: TAV=bluebird
83+
script: 'if [[ "$TRAVIS_EVENT_TYPE" == "cron" || ("$TRAVIS_EVENT_TYPE" == "pull_request" && "$TRAVIS_BRANCH" != greenkeeper/*) ]]; then tav --quiet; fi'
84+
-
85+
node_js: '10'
86+
env: TAV=knex,ws,graphql,express-graphql,elasticsearch,hapi,express
87+
script: 'if [[ "$TRAVIS_EVENT_TYPE" == "cron" || ("$TRAVIS_EVENT_TYPE" == "pull_request" && "$TRAVIS_BRANCH" != greenkeeper/*) ]]; then tav --quiet; fi'
88+
6589
# Node.js 9
6690
- stage: dependencies
6791
node_js: '9'

docs/compatibility.asciidoc

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,9 @@ image::https://github.com/raw/nodejs/Release/master/schedule.png[]
1515
Some versions of Node.js contain bugs or issues that limit our ability to instrument them correctly.
1616
The following versions of Node.js are known to not be fully instrumented:
1717

18-
- v8.0.x - Recommended solution: Upgrade to v8.2.0 or higher to get full support
18+
- v10.x - Async/Await in Node.js 10 is currently buggy and can therefore not be supported (https://github.com/nodejs/node/issues/20516:[nodejs/node#20516])
1919
- v8.1.x - Recommended solution: Upgrade to v8.2.0 or higher to get full support
20+
- v8.0.x - Recommended solution: Upgrade to v8.2.0 or higher to get full support
2021

2122
NOTE: Support for Node.js 8.2.0 and above is experimental as it makes use of the experimental core API https://nodejs.org/api/async_hooks.html[Async Hooks].
2223
If you experience any issues related to using Async Hooks,

test/.jenkins_nodejs.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
NODEJS_VERSION:
2+
- "10"
23
- "9"
34
- "8"
45
- "6"

test/.jenkins_tav_nodejs.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
NODEJS_VERSION:
2+
- "10"
23
- "9"
34
- "8"
45
- "6"

test/instrumentation/modules/hapi.js

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -13,6 +13,9 @@ var semver = require('semver')
1313
// hapi 17+ requires Node.js 8.9.0 or higher
1414
if (semver.lt(process.version, '8.9.0') && semver.gte(pkg.version, '17.0.0')) process.exit()
1515

16+
// hapi does not work on Node.js 10 because of https://github.com/nodejs/node/issues/20516
17+
if (semver.gte(process.version, '10.0.0')) process.exit()
18+
1619
var http = require('http')
1720

1821
var Hapi = require('hapi')

0 commit comments

Comments
 (0)