Skip to content
This repository has been archived by the owner on Apr 15, 2020. It is now read-only.

Commit

Permalink
chore(ci): upgrade to nyc
Browse files Browse the repository at this point in the history
  • Loading branch information
yaacovCR committed Feb 27, 2020
1 parent f1c21ba commit f32b17c
Show file tree
Hide file tree
Showing 3 changed files with 21 additions and 16 deletions.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -6,3 +6,4 @@ dist
.DS_Store
package-lock.json
.eslintcache
.nyc_output
28 changes: 16 additions & 12 deletions .travis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -4,25 +4,29 @@ node_js:
- "12"
- "10"

install:
env:
- GRAPHQL_VERSION='0.12'
- GRAPHQL_VERSION='0.13'
- GRAPHQL_VERSION='14'
- GRAPHQL_VERSION='rc'

install:
- npm config set spin=false
- npm install -g mocha coveralls
- npm install

script:
- node_version=$(node -v); if [[ ${node_version:1:2} == 13 && $GRAPHQL_VERSION == 14 ]]; then npm run lint; fi
- node_version=$(node -v); if [[ ${node_version:1:2} == 13 && $GRAPHQL_VERSION == 14 ]]; then npm run prettier:check; fi
- node_version=$(node -v); if [[ ${node_version:1:2} == 13 && $GRAPHQL_VERSION == 14 ]]; then
npm run lint;
fi
- node_version=$(node -v); if [[ ${node_version:1:2} == 13 && $GRAPHQL_VERSION == 14 ]]; then
npm run prettier:check;
fi
- npm run compile
- npm install graphql@$GRAPHQL_VERSION
- npm run testonly
- npm run testonly:cover

after_success:
- npm run coverage
- coveralls < ./coverage/lcov.info || true # if coveralls doesn't have it covered

# Allow Travis tests to run in containers.
sudo: false

env:
- GRAPHQL_VERSION='0.12'
- GRAPHQL_VERSION='0.13'
- GRAPHQL_VERSION='14'
- GRAPHQL_VERSION='rc'
8 changes: 4 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,9 @@
"lint:watch": "esw --watch --cache --ext .js,.ts src",
"watch": "tsc -w",
"testonly": "mocha --reporter spec --full-trace ./dist/test/**.js --require source-map-support/register",
"testonly:cover": "nyc npm run testonly",
"testonly:watch": "mocha -w --reporter spec --full-trace ./dist/test/**.js --require source-map-support/register",
"coverage": "istanbul cover _mocha -- --reporter dot --full-trace ./dist/test/**.js",
"postcoverage": "remap-istanbul --input coverage/coverage.json --type lcovonly --output coverage/lcov.info",
"coverage": "nyc report --reporter=text-lcov | coveralls",
"prepublishOnly": "npm run compile",
"prettier": "prettier --trailing-comma all --single-quote --write src/**/*.ts",
"prettier:check": "prettier --trailing-comma all --single-quote --check src/**/*.ts",
Expand Down Expand Up @@ -74,6 +74,7 @@
"babel-eslint": "^10.1.0",
"body-parser": "^1.19.0",
"chai": "^4.2.0",
"coveralls": "^3.0.9",
"dataloader": "^2.0.0",
"dateformat": "^3.0.3",
"eslint": "^6.8.0",
Expand All @@ -85,10 +86,9 @@
"graphql-subscriptions": "^1.1.0",
"graphql-type-json": "^0.3.1",
"graphql-upload": "^10.0.0",
"istanbul": "^0.4.5",
"mocha": "^7.1.0",
"nyc": "^15.0.0",
"prettier": "^1.19.1",
"remap-istanbul": "0.13.0",
"rimraf": "^3.0.2",
"source-map-support": "^0.5.16",
"standard-version": "^7.1.0",
Expand Down

0 comments on commit f32b17c

Please sign in to comment.