Skip to content

Commit

Permalink
update release workflows to work with both packages
Browse files Browse the repository at this point in the history
  • Loading branch information
mikealfare committed Oct 9, 2024
1 parent 36ef964 commit 7ec3045
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 2 deletions.
7 changes: 5 additions & 2 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,13 +17,16 @@ jobs:
python-version: '3.11'
- run: hatch run code-quality
working-directory: ./dbt-athena
- run: hatch run code-quality
working-directory: ./dbt-athena-community

unit_test:
name: 'Unit tests with coverage'
name: 'Unit tests - ${{ matrix.package }} - ${{ matrix.python-version }}'
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ['3.8', '3.9', '3.10', '3.11', '3.12']
package: ['dbt-athena', 'dbt-athena-community']
steps:
- uses: actions/checkout@v3
- name: "Setup `hatch`"
Expand All @@ -32,4 +35,4 @@ jobs:
python-version: ${{ matrix.python-version }}
- name: Test with pytest
run: hatch run unit-tests
working-directory: ./dbt-athena
working-directory: ./${{ matrix.package }}
8 changes: 8 additions & 0 deletions .github/workflows/functional-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,6 +21,9 @@ jobs:
functional-tests-pr:
name: Functional Tests - PR
uses: ./.github/workflows/functional-tests-workflow.yml
strategy:
matrix:
package: ['dbt-athena', 'dbt-athena-community']
secrets: inherit
permissions:
id-token: write
Expand All @@ -30,6 +33,7 @@ jobs:
checkout-ref: ${{ github.event.pull_request.head.ref }}
# this allows to work on fork
checkout-repository: ${{ github.event.pull_request.head.repo.full_name }}
package: ${{ matrix.package }}

# workflow that is invoked when a push to main happens
functional-tests-main:
Expand All @@ -39,10 +43,14 @@ jobs:
|| github.event_name == 'workflow_dispatch'
|| github.event_name == 'workflow_call'
uses: ./.github/workflows/functional-tests-workflow.yml
strategy:
matrix:
package: ['dbt-athena', 'dbt-athena-community']
secrets: inherit
permissions:
id-token: write
contents: read
with:
checkout-ref: ${{ github.ref }}
checkout-repository: ${{ github.repository }}
package: ${{ matrix.package }}

0 comments on commit 7ec3045

Please sign in to comment.