From f129d5063aae99d9d750c5cc6468c427567551d8 Mon Sep 17 00:00:00 2001 From: Jeffrey Lim Date: Wed, 26 Jun 2024 12:15:16 +0200 Subject: [PATCH 1/3] Bring testing pipelines over from epochalyst --- ...ge-testing.yml => main-branch-testing.yml} | 7 ++-- .github/workflows/version-branch-testing.yml | 33 +++++++++++++++++++ 2 files changed, 36 insertions(+), 4 deletions(-) rename .github/workflows/{python-package-testing.yml => main-branch-testing.yml} (91%) create mode 100644 .github/workflows/version-branch-testing.yml diff --git a/.github/workflows/python-package-testing.yml b/.github/workflows/main-branch-testing.yml similarity index 91% rename from .github/workflows/python-package-testing.yml rename to .github/workflows/main-branch-testing.yml index 90902c8..bcf01f2 100644 --- a/.github/workflows/python-package-testing.yml +++ b/.github/workflows/main-branch-testing.yml @@ -4,21 +4,20 @@ on: push: branches: [ "main" ] pull_request: - branches: [ "main", "v*" ] + branches: [ "main" ] jobs: build: - runs-on: ubuntu-latest container: - image: python:3.11-slim + image: python:3.10-slim env: NODE_VERSION: 20 strategy: fail-fast: false matrix: - python-version: ["3.10", "3.11"] + python-version: ["3.10", "3.11", "3.12"] steps: - name: Install Node.js diff --git a/.github/workflows/version-branch-testing.yml b/.github/workflows/version-branch-testing.yml new file mode 100644 index 0000000..f325cba --- /dev/null +++ b/.github/workflows/version-branch-testing.yml @@ -0,0 +1,33 @@ +name: Version Branch CI/CD + +on: + pull_request: + branches: ["v*"] + +jobs: + pytest: + runs-on: ubuntu-latest + steps: + - name: Check out repository + uses: actions/checkout@v4.1.6 + with: + fetch-depth: 0 + - name: Install the latest version of Rye + uses: eifinger/setup-rye@v3.0.2 + - name: Setup the environment + run: rye sync --all-features + - name: Test with pytest + run: rye run pytest --cov=agogos --cov-branch --cov-fail-under=95 tests + + build: + runs-on: ubuntu-latest + steps: + - name: Check out repository + uses: actions/checkout@v4.1.6 + - name: Install the latest version of Rye + uses: eifinger/setup-rye@v3.0.2 + - name: Build the package + run: rye build + - uses: actions/upload-artifact@v4.3.3 + with: + path: ./dist From 35cdd456c765d34eb734ad754af9cd78aa85c8b8 Mon Sep 17 00:00:00 2001 From: Jeffrey Lim Date: Wed, 26 Jun 2024 12:17:47 +0200 Subject: [PATCH 2/3] Rename to tests --- .github/workflows/version-branch-testing.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/version-branch-testing.yml b/.github/workflows/version-branch-testing.yml index f325cba..de8c495 100644 --- a/.github/workflows/version-branch-testing.yml +++ b/.github/workflows/version-branch-testing.yml @@ -5,7 +5,7 @@ on: branches: ["v*"] jobs: - pytest: + tests: runs-on: ubuntu-latest steps: - name: Check out repository From 1276aeb1bdff6857e88ac3775e47a3b2a519a03b Mon Sep 17 00:00:00 2001 From: Jeffrey Lim Date: Wed, 26 Jun 2024 12:20:29 +0200 Subject: [PATCH 3/3] Update version-branch-testing.yml --- .github/workflows/version-branch-testing.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/version-branch-testing.yml b/.github/workflows/version-branch-testing.yml index de8c495..f325cba 100644 --- a/.github/workflows/version-branch-testing.yml +++ b/.github/workflows/version-branch-testing.yml @@ -5,7 +5,7 @@ on: branches: ["v*"] jobs: - tests: + pytest: runs-on: ubuntu-latest steps: - name: Check out repository