mirror of
https://github.com/FlipsideCrypto/aleo-models.git
synced 2026-02-06 11:47:05 +00:00
updated workflows and added integration testing at AE's request
This commit is contained in:
parent
acaada3138
commit
090590489c
17
.github/workflows/dbt_integration_test.yml
vendored
Normal file
17
.github/workflows/dbt_integration_test.yml
vendored
Normal file
@ -0,0 +1,17 @@
|
||||
name: dbt_run_integration_test
|
||||
run-name: ${{ github.event.inputs.branch }}
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
|
||||
concurrency: ${{ github.workflow }}
|
||||
|
||||
jobs:
|
||||
called_workflow_template:
|
||||
uses: FlipsideCrypto/analytics-workflow-templates/.github/workflows/dbt.yml@main
|
||||
with:
|
||||
command: >
|
||||
dbt test --selector 'integration_tests'
|
||||
environment: ${{ github.ref == 'refs/heads/main' && 'workflow_prod' || 'workflow_dev' }}
|
||||
warehouse: ${{ vars.WAREHOUSE }}
|
||||
secrets: inherit
|
||||
47
.github/workflows/dbt_run_deployment.yml
vendored
47
.github/workflows/dbt_run_deployment.yml
vendored
@ -1,47 +0,0 @@
|
||||
name: dbt_run_deployment
|
||||
run-name: dbt_run_deployment
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
branches:
|
||||
- "main"
|
||||
inputs:
|
||||
warehouse:
|
||||
type: choice
|
||||
description: Snowflake warehouse
|
||||
required: true
|
||||
options:
|
||||
- DBT
|
||||
- DBT_CLOUD
|
||||
- DBT_EMERGENCY
|
||||
default: DBT
|
||||
dbt_command:
|
||||
type: string
|
||||
description: 'DBT Run Command'
|
||||
required: true
|
||||
|
||||
env:
|
||||
USE_VARS: "${{ vars.USE_VARS }}"
|
||||
DBT_PROFILES_DIR: "${{ vars.DBT_PROFILES_DIR }}"
|
||||
DBT_VERSION: "${{ vars.DBT_VERSION }}"
|
||||
ACCOUNT: "${{ vars.ACCOUNT }}"
|
||||
ROLE: "${{ vars.ROLE }}"
|
||||
USER: "${{ vars.USER }}"
|
||||
PASSWORD: "${{ secrets.PASSWORD }}"
|
||||
REGION: "${{ vars.REGION }}"
|
||||
DATABASE: "${{ vars.DATABASE }}"
|
||||
WAREHOUSE: "${{ inputs.WAREHOUSE }}"
|
||||
SCHEMA: "${{ vars.SCHEMA }}"
|
||||
|
||||
concurrency:
|
||||
group: ${{ github.workflow }}
|
||||
|
||||
jobs:
|
||||
called_workflow_template:
|
||||
uses: FlipsideCrypto/analytics-workflow-templates/.github/workflows/dbt_run_deployment_template.yml@AN-4374/upgrade-dbt-1.7
|
||||
with:
|
||||
dbt_command: |
|
||||
${{ inputs.dbt_command }}
|
||||
environment: workflow_prod
|
||||
warehouse: ${{ inputs.WAREHOUSE }}
|
||||
secrets: inherit
|
||||
46
.github/workflows/dbt_run_non_core.yml
vendored
46
.github/workflows/dbt_run_non_core.yml
vendored
@ -1,46 +0,0 @@
|
||||
name: dbt_run_non_core
|
||||
run-name: dbt_run_non_core
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
# schedule:
|
||||
# # Runs "at minute 7 and 37, every hour" (see https://crontab.guru)
|
||||
# - cron: '10 * * * *'
|
||||
|
||||
env:
|
||||
USE_VARS: "${{ vars.USE_VARS }}"
|
||||
DBT_PROFILES_DIR: "${{ vars.DBT_PROFILES_DIR }}"
|
||||
DBT_VERSION: "${{ vars.DBT_VERSION }}"
|
||||
ACCOUNT: "${{ vars.ACCOUNT }}"
|
||||
ROLE: "${{ vars.ROLE }}"
|
||||
USER: "${{ vars.USER }}"
|
||||
PASSWORD: "${{ secrets.PASSWORD }}"
|
||||
REGION: "${{ vars.REGION }}"
|
||||
DATABASE: "${{ vars.DATABASE }}"
|
||||
WAREHOUSE: "${{ vars.WAREHOUSE }}"
|
||||
SCHEMA: "${{ vars.SCHEMA }}"
|
||||
|
||||
concurrency:
|
||||
group: ${{ github.workflow }}
|
||||
|
||||
jobs:
|
||||
run_dbt_jobs:
|
||||
runs-on: ubuntu-latest
|
||||
environment:
|
||||
name: workflow_prod
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
- uses: actions/setup-python@v4
|
||||
with:
|
||||
python-version: "${{ vars.PYTHON_VERSION }}"
|
||||
cache: "pip"
|
||||
|
||||
- name: install dependencies
|
||||
run: |
|
||||
pip install -r requirements.txt
|
||||
dbt deps
|
||||
- name: Run DBT Jobs
|
||||
run: |
|
||||
dbt run -m "aleo_models,tag:noncore"
|
||||
47
.github/workflows/dbt_test_recent.yml
vendored
47
.github/workflows/dbt_test_recent.yml
vendored
@ -1,47 +0,0 @@
|
||||
name: dbt_test_recent
|
||||
run-name: dbt_test_recent
|
||||
|
||||
on:
|
||||
workflow_dispatch:
|
||||
# schedule:
|
||||
# # Daily at 8:30am UTC
|
||||
# - cron: '30 8 * * *'
|
||||
|
||||
env:
|
||||
USE_VARS: "${{ vars.USE_VARS }}"
|
||||
DBT_PROFILES_DIR: "${{ vars.DBT_PROFILES_DIR }}"
|
||||
DBT_VERSION: "${{ vars.DBT_VERSION }}"
|
||||
ACCOUNT: "${{ vars.ACCOUNT }}"
|
||||
ROLE: "${{ vars.ROLE }}"
|
||||
USER: "${{ vars.USER }}"
|
||||
PASSWORD: "${{ secrets.PASSWORD }}"
|
||||
REGION: "${{ vars.REGION }}"
|
||||
DATABASE: "${{ vars.DATABASE }}"
|
||||
WAREHOUSE: "${{ vars.WAREHOUSE }}"
|
||||
SCHEMA: "${{ vars.SCHEMA }}"
|
||||
|
||||
concurrency:
|
||||
group: ${{ github.workflow }}
|
||||
|
||||
jobs:
|
||||
run_dbt_jobs:
|
||||
runs-on: ubuntu-latest
|
||||
environment:
|
||||
name: workflow_prod
|
||||
|
||||
steps:
|
||||
- uses: actions/checkout@v3
|
||||
|
||||
- uses: actions/setup-python@v4
|
||||
with:
|
||||
python-version: "${{ vars.PYTHON_VERSION }}"
|
||||
cache: "pip"
|
||||
|
||||
- name: install dependencies
|
||||
run: |
|
||||
pip install -r requirements.txt
|
||||
dbt deps
|
||||
- name: Run DBT Jobs
|
||||
run: |
|
||||
dbt run -m "aleo_models,tag:recent_test"
|
||||
dbt test -m "aleo_models,tag:recent_test"
|
||||
@ -1,6 +1,4 @@
|
||||
workflow_name,workflow_schedule
|
||||
dbt_run_streamline_blocks_realtime,"5,35 * * * *"
|
||||
dbt_run_core,"20,50 * * * *"
|
||||
dbt_run_non_core,"30,50 * * * *"
|
||||
dbt_test_recent,"20 */4 * * *"
|
||||
dbt_test_tasks,"0,30 * * * *"
|
||||
|
8
selectors.yml
Normal file
8
selectors.yml
Normal file
@ -0,0 +1,8 @@
|
||||
selectors:
|
||||
- name: integration_tests
|
||||
description: "Selector for integration tests"
|
||||
definition:
|
||||
union:
|
||||
- method: fqn
|
||||
value: "livequery_models.deploy.core.*"
|
||||
|
||||
Loading…
Reference in New Issue
Block a user