Add/premio oceanos #9
Workflow file for this run
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: Test DBT model | |
on: | |
pull_request: | |
types: [labeled, opened] | |
branches: | |
- main | |
paths: | |
- 'models/**' | |
- '.github/workflows/test_dbt_model.yaml' | |
jobs: | |
test_dbt_model: | |
if: contains(github.event.pull_request.labels.*.name, 'test-dev-model') | |
name: Test DBT dev model | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout | |
uses: actions/checkout@v3 | |
with: | |
ref: ${{ github.head_ref }} | |
- name: Get all changed files using a comma separator | |
id: changed-files | |
uses: tj-actions/changed-files@v35 | |
with: | |
separator: ',' | |
- name: Setup Python 3.9 | |
uses: actions/setup-python@v2 | |
with: | |
python-version: 3.9 | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install -r requirements-actions.txt | |
- name: Run script to test DBT model | |
run: | | |
python .github/workflows/scripts/table_test.py --modified-files ${{ steps.changed-files.outputs.all_modified_files }} --graphql-url ${{ secrets.BACKEND_GRAPHQL_URL }} --prefect-backend-token ${{ secrets.PREFECT_BACKEND_TOKEN }} |