Skip to content

feat: add integration test on CI #88

feat: add integration test on CI

feat: add integration test on CI #88

Workflow file for this run

name: Tests
on:
pull_request:
branches: [ main ]
jobs:
test:
runs-on: [ ubuntu-latest ]
strategy:
fail-fast: false
matrix:
airflow-version: [ "2.6.3", "2.7.3", "2.8.4", "2.9.3", "2.10.0", "2.10.1", "2.10.2", "2.10.3", "2.10.4" ]
python-version: [ "3.10", "3.11" ]
steps:
- uses: actions/checkout@v4
- name: Set up Docker Buildx
uses: docker/setup-buildx-action@v3
- name: Docker build
uses: docker/build-push-action@v6
with:
context: .
outputs: type=docker
push: false
tags: "dbt-af-${{ matrix.airflow-version }}-py${{ matrix.python-version }}-ci"
cache-from: type=gha
cache-to: type=gha,mode=max
build-args: |
AIRFLOW_USE_UV="true"
AIRFLOW_VERSION=${{ matrix.airflow-version }}
PYTHON_VERSION=${{ matrix.python-version }}
- name: Run tests in container
run: |
docker run \
--entrypoint="" \
dbt-af-${{ matrix.airflow-version }}-py${{ matrix.python-version }}-ci \
bash -c "airflow db migrate && pytest -q -s -vv --log-cli-level=INFO --cov=dbt_af --cov-report=term --run-airflow-tasks tests"