Skip to content

Commit 83802d2

Browse files
committed
Update CI workflows and Node.js test scripts
1 parent 2c88fd1 commit 83802d2

File tree

4 files changed

+50
-52
lines changed

4 files changed

+50
-52
lines changed

.github/workflows/node.yml

Lines changed: 17 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,33 +1,37 @@
11
# This workflow will do a clean install of node dependencies, build the source code and run tests across different versions of node
2-
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions
32

43
name: Node.js CI
54

65
on:
76
push:
8-
branches: [ master ]
7+
branches: [ main ]
98
paths:
109
- 'nodejs/**'
1110
- .github/workflows/node.yml
1211
pull_request:
13-
branches: [ master ]
12+
branches: [ main ]
1413
paths:
1514
- 'nodejs/**'
15+
- .github/workflows/node.yml
1616

17-
jobs:
18-
build:
17+
permissions:
18+
contents: read
1919

20+
jobs:
21+
test:
2022
runs-on: ubuntu-latest
2123

2224
strategy:
2325
matrix:
24-
node-version: [16, 18, 20]
26+
node-version: [ 20, 22, 24 ]
2527

2628
steps:
27-
- uses: actions/checkout@v4
28-
- name: Use Node.js ${{ matrix.node-version }}
29-
uses: actions/setup-node@v4
30-
with:
31-
node-version: ${{ matrix.node-version }}
32-
- run: cd nodejs; npm ci
33-
- run: cd nodejs; node test.js dump verbose
29+
- uses: actions/checkout@v6
30+
- name: Use Node.js ${{ matrix.node-version }}
31+
uses: actions/setup-node@v6
32+
with:
33+
node-version: ${{ matrix.node-version }}
34+
- name: Install dependencies
35+
run: cd nodejs && npm install
36+
- name: Run tests
37+
run: cd nodejs && npm run test:verbose

.github/workflows/python.yml

Lines changed: 31 additions & 22 deletions
Original file line numberDiff line numberDiff line change
@@ -1,41 +1,50 @@
11
# This workflow will install Python dependencies, run tests and lint with a variety of Python versions
2-
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions
32

43
name: Python package
54

65
on:
76
push:
8-
branches: [ master ]
7+
branches: [ main ]
98
paths:
109
- 'python/**'
1110
- .github/workflows/python.yml
1211
pull_request:
13-
branches: [ master ]
12+
branches: [ main ]
1413
paths:
1514
- 'python/**'
15+
- .github/workflows/python.yml
1616

17-
jobs:
18-
build:
17+
permissions:
18+
contents: read
1919

20+
jobs:
21+
test:
2022
runs-on: ubuntu-latest
23+
2124
strategy:
2225
matrix:
23-
python-version: ['3.7', '3.8', '3.9']
26+
python-version: [
27+
'3.10',
28+
'3.11',
29+
'3.12',
30+
'3.13',
31+
'3.14',
32+
]
2433

2534
steps:
26-
- uses: actions/checkout@v2
27-
- name: Set up Python ${{ matrix.python-version }}
28-
uses: actions/setup-python@v4
29-
with:
30-
python-version: ${{ matrix.python-version }}
31-
- name: Install dependencies
32-
run: |
33-
python -m pip install --upgrade pip
34-
pip install black nose
35-
cd python; pip install -r requirements.txt
36-
- name: Reformat
37-
run: |
38-
cd python; black --check .
39-
- name: Run tests
40-
run: |
41-
cd python; nosetests
35+
- uses: actions/checkout@v6
36+
- name: Set up Python ${{ matrix.python-version }}
37+
uses: actions/setup-python@v6
38+
with:
39+
python-version: ${{ matrix.python-version }}
40+
- name: Install dependencies
41+
run: |
42+
python -m pip install --upgrade pip
43+
pip install black tox tox-gh
44+
cd python && pip install -r requirements.txt
45+
- name: Run tests
46+
run: cd python && tox
47+
env:
48+
TOX_GH_MAJOR_MINOR: ${{ matrix.python-version }}
49+
- name: Check formatting
50+
run: cd python && black --check .

nodejs/package-lock.json

Lines changed: 0 additions & 16 deletions
This file was deleted.

nodejs/package.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,8 @@
1919
"license": "MIT",
2020
"main": "./ece.js",
2121
"scripts": {
22-
"test": "node ./test.js"
22+
"test": "node ./test.js",
23+
"test:verbose": "node ./test.js dump verbose"
2324
},
2425
"engines": {
2526
"node": ">=16"

0 commit comments

Comments
 (0)