@@ -36,16 +36,21 @@ jobs:
3636 # exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide
3737 flake8 . --count --exit-zero --max-complexity=10 --max-line-length=127 --statistics
3838
39- - name : Test with pytest
39+ - name : Run unit tests
40+ shell : bash -l {0}
4041 run : |
41- pytest --cov=chartlets
42-
42+ pytest --cov=chartlets --cov-report=xml
43+
4344 - name : Upload coverage reports to Codecov
4445 uses : codecov/codecov-action@v4
45- env :
46- CODECOV_TOKEN : ${{ secrets.CODECOV_TOKEN }}
46+ with :
47+ fail_ci_if_error : true
48+ directory : chartlets.py/
49+ flags : backend
50+ verbose : true
51+ token : ${{ secrets.CODECOV_TOKEN }}
4752
48- PyPi-deploy :
53+ PyPi-Deploy :
4954 name : Publish Python Package to PyPI
5055 runs-on : ubuntu-latest
5156 needs : python-tests
7782 password : ${{ secrets.PYPI_API_TOKEN }}
7883 packages_dir : chartlets.py/dist
7984 verbose : true
80-
81- npm-tests :
82- runs-on : ubuntu-latest
83- strategy :
84- matrix :
85- node-version : [16.x, 18.x, 20.x]
86- # See supported Node.js release schedule at
87- # https://nodejs.org/en/about/releases/
88- defaults :
89- run :
90- working-directory : chartlets.js
91-
92- steps :
93- - uses : actions/checkout@v3
94- - name : Use Node.js ${{ matrix.node-version }}
95- uses : actions/setup-node@v3
96- with :
97- node-version : ${{ matrix.node-version }}
98- cache : ' npm'
99- cache-dependency-path : chartlets.js/package-lock.json
100-
101- - run : npm ci
102- - run : npm run lint
103- - run : npm run build
104- - run : npm run test
105-
106- npm-Deploy :
107- name : Publish TS-React Package to npmjs
108- runs-on : ubuntu-latest
109- needs : npm-tests
110- defaults :
111- run :
112- working-directory : chartlets.js
113-
114- steps :
115- - uses : actions/checkout@v4
116-
117- - name : Set up Node.js
118- uses : actions/setup-node@v4
119- with :
120- node-version : ' 18.x'
121- registry-url : ' https://registry.npmjs.org'
122- cache : ' npm'
123- cache-dependency-path : chartlets.js/package-lock.json
124-
125- - run : npm ci
126- - run : npm run build
127- - run : npm publish --access public
128- env :
129- NODE_AUTH_TOKEN : ${{ secrets.NPM_TOKEN }}
0 commit comments