From a7cae25124fe832b034ae17e1e9255bf87ff4034 Mon Sep 17 00:00:00 2001 From: "M. Zain Sohail" Date: Wed, 11 Oct 2023 03:37:22 +0200 Subject: [PATCH] lfs and test matrix --- .github/workflows/documentation.yml | 4 +++- .../workflows/{cache_setup.yml => testing.yml} | 15 ++++++++++++--- 2 files changed, 15 insertions(+), 4 deletions(-) rename .github/workflows/{cache_setup.yml => testing.yml} (67%) diff --git a/.github/workflows/documentation.yml b/.github/workflows/documentation.yml index 994c4159..f8ee8b5c 100644 --- a/.github/workflows/documentation.yml +++ b/.github/workflows/documentation.yml @@ -6,12 +6,14 @@ on: branches: [ workflow_trials ] jobs: - cache: + pytest: runs-on: ubuntu-latest steps: # Check out repo and set up Python - name: Check out the repository uses: actions/checkout@v4 + with: + lfs: true - name: "Setup Python, Poetry and Dependencies" uses: packetcoders/action-setup-cache-python-poetry@main diff --git a/.github/workflows/cache_setup.yml b/.github/workflows/testing.yml similarity index 67% rename from .github/workflows/cache_setup.yml rename to .github/workflows/testing.yml index 52a71685..517b9f6a 100644 --- a/.github/workflows/cache_setup.yml +++ b/.github/workflows/testing.yml @@ -1,11 +1,15 @@ -name: test +name: pytest on: push: branches: [ workflow_trials ] jobs: - cache: + pytest: + # Using matrix strategy + strategy: + matrix: + python-version: ["3.8", "3.9", "3.10"] runs-on: ubuntu-latest steps: #-------------------------------------# @@ -13,13 +17,18 @@ jobs: #-------------------------------------# - name: Check out the repository uses: actions/checkout@v4 + with: + lfs: true - name: "Setup Python, Poetry and Dependencies" uses: packetcoders/action-setup-cache-python-poetry@main with: - python-version: 3.8 + python-version: ${{matrix.python-version}} poetry-version: 1.2.2 #------------------------# # Run your actual job # #------------------------# + - name: Run tests + run: | + poetry run pytest