Move tests into main workflows.

The workflow UI works best if there's only a single main workflow in a
PR. We can keep things organized similarly by turning the test workflow
into a reusable workflow. Same code (mostly), better UI.
This commit is contained in:
Dan Albert 2022-07-27 20:24:21 -07:00
parent 6437700a61
commit 151cf17e35
3 changed files with 12 additions and 20 deletions

View File

@ -6,6 +6,9 @@ jobs:
lint:
uses: ./.github/workflows/lint.yml
test:
uses: ./.github/workflows/test.yml
build:
runs-on: windows-latest
steps:

View File

@ -8,6 +8,9 @@ jobs:
lint:
uses: ./.github/workflows/lint.yml
test:
uses: ./.github/workflows/test.yml
build:
runs-on: windows-latest
steps:

View File

@ -1,30 +1,16 @@
name: Test
on: [push, pull_request]
name: Tests
on: workflow_call
jobs:
build:
python-tests:
name: Python tests
runs-on: windows-latest
steps:
- uses: actions/checkout@v2
with:
submodules: true
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: "3.10"
- name: Install environment
run: |
python -m venv ./venv
- name: Install dependencies
run: |
./venv/scripts/activate
python -m pip install -r requirements.txt
# For some reason the shiboken2.abi3.dll is not found properly, so I copy it instead
Copy-Item .\venv\Lib\site-packages\shiboken2\shiboken2.abi3.dll .\venv\Lib\site-packages\PySide2\ -Force
- name: Set up Python environment
uses: ./.github/actions/setup-liberation-python
- name: run tests
run: |