Update Managed Files #480
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Run Test Suite | |
on: | |
workflow_dispatch: | |
push: | |
branches: | |
- main | |
tags: | |
- '**' | |
pull_request: | |
branches: | |
- '**' | |
concurrency: | |
group: ${{ github.ref }}-${{ github.workflow }}-${{ github.event_name }}--${{ (github.ref == 'refs/heads/main' || startsWith(github.ref, 'refs/heads/release/') || startsWith(github.ref, 'refs/heads/long_lived/')) && github.sha || '' }} | |
cancel-in-progress: true | |
defaults: | |
run: | |
shell: bash | |
jobs: | |
build: | |
name: Test - ${{ matrix.os.name }} ${{ matrix.python.major-dot-minor }} ${{ matrix.arch.name }} | |
runs-on: ${{ matrix.os.runs-on[matrix.arch.matrix] }} | |
timeout-minutes: 30 | |
strategy: | |
fail-fast: false | |
matrix: | |
os: | |
- name: macOS | |
matrix: macos | |
runs-on: | |
arm: macos-13-arm64 | |
intel: [macos-13] | |
- name: Ubuntu | |
matrix: ubuntu | |
runs-on: | |
arm: [Linux, ARM64] | |
intel: [ubuntu-latest] | |
- name: Windows | |
matrix: windows | |
runs-on: | |
intel: [windows-latest] | |
python: | |
- major-dot-minor: '3.9' | |
matrix: '3.9' | |
- major-dot-minor: '3.10' | |
matrix: '3.10' | |
- major-dot-minor: '3.11' | |
matrix: '3.11' | |
- major-dot-minor: '3.12' | |
matrix: '3.12' | |
arch: | |
- name: ARM | |
matrix: arm | |
- name: Intel | |
matrix: intel | |
exclude: | |
- os: | |
matrix: windows | |
arch: | |
matrix: arm | |
- os: | |
matrix: macos | |
arch: | |
matrix: arm | |
steps: | |
- name: Clean workspace | |
uses: Chia-Network/actions/clean-workspace@main | |
- name: Checkout Code | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- uses: Chia-Network/actions/setup-python@main | |
with: | |
python-version: ${{ matrix.python.major-dot-minor }} | |
- uses: Chia-Network/actions/create-venv@main | |
id: create-venv | |
- uses: Chia-Network/actions/activate-venv@main | |
with: | |
directories: ${{ steps.create-venv.outputs.activate-venv-directories }} | |
- name: Test code with pytest | |
if: runner.os == 'Linux' || runner.os == 'macOS' | |
shell: bash | |
run: | | |
python3 -m venv venv | |
. ./venv/bin/activate | |
pip install ."[dev]" | |
./venv/bin/chia init | |
./venv/bin/pytest tests/ cdv/examples/tests -s -v --durations 0 | |
- name: Test code with pytest | |
if: runner.os == 'Windows' | |
shell: powershell | |
run: | | |
python -m pip install --upgrade pip | |
pip install .[dev] | |
chia init | |
pytest tests\ cdv\examples\tests -s -v --durations 0 |