Skip to content

Commit

Permalink
test: refine test workflow
Browse files Browse the repository at this point in the history
  • Loading branch information
yndu13 authored and JacksonTian committed Dec 6, 2023
1 parent 4c90a87 commit b7ad9a2
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 15 deletions.
6 changes: 3 additions & 3 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,7 @@ jobs:

strategy:
matrix:
node-version: [12.x, 14.x, 16.x]
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/
node-version: [12.x, 14.x, 16.x, 18.x, 20.x]

steps:
- uses: actions/checkout@v2
Expand All @@ -27,4 +26,5 @@ jobs:
node-version: ${{ matrix.node-version }}
- run: npm install
- run: npm run ci
- run: npm run test
- name: Upload coverage to Codecov
uses: codecov/codecov-action@v3
6 changes: 2 additions & 4 deletions README-CN.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,15 @@

# Darabonba Python 生成器

[![NPM version][npm-image]][npm-url]
[![CI](https://github.com/aliyun/darabonba-python-generator/actions/workflows/ci.yml/badge.svg)](https://github.com/aliyun/darabonba-python-generator/actions/workflows/ci.yml)
[![codecov][cov-image]][cov-url]
[![David deps][david-image]][david-url]
[![NPM version][npm-image]][npm-url]
[![npm download][download-image]][download-url]

[npm-image]: https://img.shields.io/npm/v/@darabonba/python-generator.svg?style=flat-square
[npm-url]: https://npmjs.org/package/@darabonba/python-generator
[cov-image]: https://codecov.io/gh/aliyun/darabonba-python-generator/branch/master/graph/badge.svg
[cov-url]: https://codecov.io/gh/aliyun/darabonba-python-generator
[david-image]: https://img.shields.io/david/aliyun/darabonba-python-generator.svg?style=flat-square
[david-url]: https://david-dm.org/aliyun/darabonba-python-generator
[download-image]: https://img.shields.io/npm/dm/@darabonba/python-generator.svg?style=flat-square
[download-url]: https://npmjs.org/package/@darabonba/python-generator

Expand Down
6 changes: 2 additions & 4 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,17 +2,15 @@ English | [简体中文](/README-CN.md)

# Darabonba Python Generator

[![NPM version][npm-image]][npm-url]
[![CI](https://github.com/aliyun/darabonba-python-generator/actions/workflows/ci.yml/badge.svg)](https://github.com/aliyun/darabonba-python-generator/actions/workflows/ci.yml)
[![codecov][cov-image]][cov-url]
[![David deps][david-image]][david-url]
[![NPM version][npm-image]][npm-url]
[![npm download][download-image]][download-url]

[npm-image]: https://img.shields.io/npm/v/@darabonba/python-generator.svg?style=flat-square
[npm-url]: https://npmjs.org/package/@darabonba/python-generator
[cov-image]: https://codecov.io/gh/aliyun/darabonba-python-generator/branch/master/graph/badge.svg
[cov-url]: https://codecov.io/gh/aliyun/darabonba-python-generator
[david-image]: https://img.shields.io/david/aliyun/darabonba-python-generator.svg?style=flat-square
[david-url]: https://david-dm.org/aliyun/darabonba-python-generator
[download-image]: https://img.shields.io/npm/dm/@darabonba/python-generator.svg?style=flat-square
[download-url]: https://npmjs.org/package/@darabonba/python-generator

Expand Down
7 changes: 3 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -8,17 +8,16 @@
},
"scripts": {
"lint": "eslint --fix src/",
"test": "mocha --reporter spec --timeout 3000 tests/*.tests.js",
"test-cov": "nyc -r=lcov -r=html -r=text -r=json mocha -t 3000 -R spec tests/*.tests.js",
"ci": "npm run lint && npm run test-cov && codecov"
"test": "mocha -R spec -t 3000 tests/*.tests.js",
"test-cov": "nyc -r=lcov -r=html -r=text -r=json npm run test",
"ci": "npm run lint && npm run test-cov"
},
"repository": {
"type": "git",
"url": "[email protected]:aliyun/darabonba-python-generator.git"
},
"devDependencies": {
"chai": "^4.2.0",
"codecov": "^3.8.1",
"eslint": "^7.14.0",
"expect.js": "^0.3.1",
"has-flag": "^4.0.0",
Expand Down

0 comments on commit b7ad9a2

Please sign in to comment.