Skip to content

Commit 0b54e0d

Browse files
authored
Merge pull request #288 from tky823/docs/coverage-report-2
Detailed build status
2 parents a80fc73 + 3275a94 commit 0b54e0d

25 files changed

+356
-37
lines changed
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
name: macos-13
2+
on:
3+
workflow_call:
4+
inputs:
5+
python-version:
6+
required: true
7+
type: string
8+
secrets:
9+
TEST_PYPI_API_TOKEN:
10+
required: true
11+
jobs:
12+
package:
13+
uses: ./.github/workflows/test_package_main.yaml
14+
with:
15+
# macos-13: x86_64, macos-latest: arm
16+
# See https://docs.github.com/en/actions/using-github-hosted-runners/about-github-hosted-runners/about-github-hosted-runners
17+
os: macos-13
18+
python-version: ${{ inputs.python-version }}
19+
secrets:
20+
TEST_PYPI_API_TOKEN: ${{ secrets.TEST_PYPI_API_TOKEN }}
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
name: macos-13/3.10
2+
on:
3+
push:
4+
branches:
5+
- main
6+
pull_request:
7+
branches:
8+
- main
9+
jobs:
10+
package:
11+
uses: ./.github/workflows/test_package_macos-13.yaml
12+
with:
13+
python-version: "3.10"
14+
secrets:
15+
TEST_PYPI_API_TOKEN: ${{ secrets.TEST_PYPI_API_TOKEN }}
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
name: macos-13/3.11
2+
on:
3+
push:
4+
branches:
5+
- main
6+
pull_request:
7+
branches:
8+
- main
9+
jobs:
10+
package:
11+
uses: ./.github/workflows/test_package_macos-13.yaml
12+
with:
13+
python-version: "3.11"
14+
secrets:
15+
TEST_PYPI_API_TOKEN: ${{ secrets.TEST_PYPI_API_TOKEN }}
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
name: macos-13/3.12
2+
on:
3+
push:
4+
branches:
5+
- main
6+
pull_request:
7+
branches:
8+
- main
9+
jobs:
10+
package:
11+
uses: ./.github/workflows/test_package_macos-13.yaml
12+
with:
13+
python-version: "3.12"
14+
secrets:
15+
TEST_PYPI_API_TOKEN: ${{ secrets.TEST_PYPI_API_TOKEN }}
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
name: macos-13/3.8
2+
on:
3+
push:
4+
branches:
5+
- main
6+
pull_request:
7+
branches:
8+
- main
9+
jobs:
10+
package:
11+
uses: ./.github/workflows/test_package_macos-13.yaml
12+
with:
13+
python-version: "3.8"
14+
secrets:
15+
TEST_PYPI_API_TOKEN: ${{ secrets.TEST_PYPI_API_TOKEN }}
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
name: macos-13/3.9
2+
on:
3+
push:
4+
branches:
5+
- main
6+
pull_request:
7+
branches:
8+
- main
9+
jobs:
10+
package:
11+
uses: ./.github/workflows/test_package_macos-13.yaml
12+
with:
13+
python-version: "3.9"
14+
secrets:
15+
TEST_PYPI_API_TOKEN: ${{ secrets.TEST_PYPI_API_TOKEN }}

.github/workflows/test_package.yaml renamed to .github/workflows/test_package_main.yaml

Lines changed: 17 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -1,27 +1,27 @@
11
name: test package
22
on:
3-
push:
4-
branches:
5-
- main
6-
pull_request:
7-
branches:
8-
- main
9-
- develop
3+
workflow_call:
4+
inputs:
5+
os:
6+
required: true
7+
type: string
8+
python-version:
9+
required: true
10+
type: string
11+
secrets:
12+
TEST_PYPI_API_TOKEN:
13+
required: true
1014
jobs:
1115
build:
1216
name: Run tests with pytest
13-
runs-on: ${{ matrix.os }}
14-
strategy:
15-
matrix:
16-
python-version: ["3.8", "3.9", "3.10", "3.11"]
17-
os: [ubuntu-latest, macos-latest, windows-latest]
17+
runs-on: ${{ inputs.os }}
1818
steps:
1919
- name: Checkout
2020
uses: actions/checkout@v4
21-
- name: Set up Python ${{ matrix.python-version }}
21+
- name: Set up Python ${{ inputs.python-version }}
2222
uses: actions/setup-python@v4
2323
with:
24-
python-version: ${{ matrix.python-version }}
24+
python-version: ${{ inputs.python-version }}
2525
- name: Install dependencies
2626
run: |
2727
python -m pip install --upgrade pip
@@ -42,13 +42,14 @@ jobs:
4242
run: |
4343
pytest -vvv -n 16 tests/regression/
4444
- name: Upload coverage to codecov
45-
if: matrix.python-version == '3.8' && matrix.os == 'ubuntu-latest'
45+
if: inputs.python-version == '3.8' && inputs.os == 'ubuntu-latest'
4646
uses: codecov/codecov-action@v3
4747
with:
4848
fail_ci_if_error: true
4949
lint:
5050
name: Run linters
5151
runs-on: ubuntu-latest
52+
if: inputs.python-version == '3.8' && inputs.os == 'ubuntu-latest'
5253
steps:
5354
- name: Checkout
5455
uses: actions/checkout@v4
@@ -76,5 +77,5 @@ jobs:
7677
id-token: write
7778
secrets:
7879
TEST_PYPI_API_TOKEN: ${{ secrets.TEST_PYPI_API_TOKEN }}
79-
if: github.event_name == 'pull_request'
80+
if: github.event_name == 'pull_request' && inputs.python-version == '3.9' && inputs.os == 'ubuntu-latest'
8081
uses: ./.github/workflows/upload_package.yaml
Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,18 @@
1+
name: macos-13
2+
on:
3+
workflow_call:
4+
inputs:
5+
python-version:
6+
required: true
7+
type: string
8+
secrets:
9+
TEST_PYPI_API_TOKEN:
10+
required: true
11+
jobs:
12+
package:
13+
uses: ./.github/workflows/test_package_main.yaml
14+
with:
15+
os: ubuntu-latest
16+
python-version: ${{ inputs.python-version }}
17+
secrets:
18+
TEST_PYPI_API_TOKEN: ${{ secrets.TEST_PYPI_API_TOKEN }}
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
name: ubuntu-latest/3.10
2+
on:
3+
push:
4+
branches:
5+
- main
6+
pull_request:
7+
branches:
8+
- main
9+
jobs:
10+
package:
11+
uses: ./.github/workflows/test_package_ubuntu-latest.yaml
12+
with:
13+
python-version: "3.10"
14+
secrets:
15+
TEST_PYPI_API_TOKEN: ${{ secrets.TEST_PYPI_API_TOKEN }}
Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,15 @@
1+
name: ubuntu-latest/3.11
2+
on:
3+
push:
4+
branches:
5+
- main
6+
pull_request:
7+
branches:
8+
- main
9+
jobs:
10+
package:
11+
uses: ./.github/workflows/test_package_ubuntu-latest.yaml
12+
with:
13+
python-version: "3.11"
14+
secrets:
15+
TEST_PYPI_API_TOKEN: ${{ secrets.TEST_PYPI_API_TOKEN }}

0 commit comments

Comments
 (0)