Skip to content

Commit

Permalink
ci: disable Codecov and measure test coverage on every run (graphql#3548
Browse files Browse the repository at this point in the history
)
  • Loading branch information
IvanGoncharov committed Apr 27, 2022
1 parent 03536f9 commit 626f2d2
Show file tree
Hide file tree
Showing 6 changed files with 3 additions and 48 deletions.
2 changes: 1 addition & 1 deletion .c8rc.json
Expand Up @@ -14,7 +14,7 @@
"temp-directory": "coverage",
"report-dir": "coverage",
"skip-full": true,
"reporter": ["json", "html", "text"],
"reporter": ["html", "text"],
"check-coverage": true,
"branches": 100,
"lines": 100,
Expand Down
30 changes: 1 addition & 29 deletions .github/workflows/ci.yml
Expand Up @@ -121,40 +121,12 @@ jobs:
- name: Run Tests
run: npm run fuzzonly

coverage:
name: Measure test coverage
runs-on: ubuntu-latest
steps:
- name: Checkout repo
uses: actions/checkout@v2
with:
persist-credentials: false

- name: Setup Node.js
uses: actions/setup-node@v2
with:
cache: npm
node-version-file: '.node-version'

- name: Install Dependencies
run: npm ci --ignore-scripts

- name: Run tests and measure code coverage
run: npm run testonly:cover

- name: Upload coverage to Codecov
if: ${{ always() }}
uses: codecov/codecov-action@v1
with:
file: ./coverage/coverage-final.json
fail_ci_if_error: true

test:
name: Run tests on Node v${{ matrix.node_version_to_setup }}
runs-on: ubuntu-latest
strategy:
matrix:
node_version_to_setup: [12, 14, 16, 17]
node_version_to_setup: [14, 16, 18]
steps:
- name: Checkout repo
uses: actions/checkout@v2
Expand Down
1 change: 0 additions & 1 deletion README.md
Expand Up @@ -4,7 +4,6 @@ The JavaScript reference implementation for GraphQL, a query language for APIs c

[![npm version](https://badge.fury.io/js/graphql.svg)](https://badge.fury.io/js/graphql)
[![Build Status](https://github.com/graphql/graphql-js/workflows/CI/badge.svg?branch=main)](https://github.com/graphql/graphql-js/actions?query=branch%3Amain)
[![Coverage Status](https://codecov.io/gh/graphql/graphql-js/branch/main/graph/badge.svg)](https://codecov.io/gh/graphql/graphql-js)

See more complete documentation at https://graphql.org/ and
https://graphql.org/graphql-js/.
Expand Down
14 changes: 0 additions & 14 deletions codecov.yml

This file was deleted.

1 change: 0 additions & 1 deletion cspell.yml
Expand Up @@ -46,7 +46,6 @@ words:

# TODO: contribute upstream
- deno
- codecov

# TODO: remove bellow words
- QLID # GraphQLID
Expand Down
3 changes: 1 addition & 2 deletions package.json
Expand Up @@ -38,8 +38,7 @@
"test": "npm run lint && npm run check && npm run testonly && npm run prettier:check && npm run check:spelling && npm run check:integrations",
"lint": "eslint --cache --max-warnings 0 .",
"check": "tsc --pretty",
"testonly": "mocha --full-trace src/**/__tests__/**/*-test.ts",
"testonly:cover": "c8 npm run testonly",
"testonly": "c8 mocha --full-trace src/**/__tests__/**/*-test.ts",
"prettier": "prettier --write --list-different .",
"prettier:check": "prettier --check .",
"check:spelling": "cspell --cache --no-progress '**/*'",
Expand Down

0 comments on commit 626f2d2

Please sign in to comment.