-
Notifications
You must be signed in to change notification settings - Fork 91
59 lines (53 loc) · 2.54 KB
/
ci.yml
File metadata and controls
59 lines (53 loc) · 2.54 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
# **what?**
# Run tests for dbt-project-evaluator against supported adapters
# **why?**
# To ensure that dbt-project-evaluator works as expected with all supported adapters
# **when?**
# On every PR, and every push to main and when manually triggered
name: Package Integration Tests
on:
push:
branches:
- main
pull_request_target:
workflow_dispatch:
permissions:
contents: read
jobs:
core-tests:
uses: dbt-labs/dbt-package-testing/.github/workflows/run_tox.yml@v2
with:
# Adapters are read from supported_adapters.env if not specified here
adapters: "snowflake,bigquery,redshift,databricks"
# For pull_request_target: require environment approval for fork PRs
environment: >-
${{ github.event_name == 'pull_request_target'
&& github.event.pull_request.head.repo.full_name != github.repository
&& 'cloud-tests' || '' }}
# For pull_request_target: checkout the PR head, not the base branch
ref: ${{ github.event.pull_request.head.sha || '' }}
# snowflake
SNOWFLAKE_USER: ${{ vars.SNOWFLAKE_USER }}
SNOWFLAKE_ROLE: ${{ vars.SNOWFLAKE_ROLE }}
SNOWFLAKE_DATABASE: ${{ vars.SNOWFLAKE_DATABASE }}
SNOWFLAKE_WAREHOUSE: ${{ vars.SNOWFLAKE_WAREHOUSE }}
SNOWFLAKE_SCHEMA: "dbt_project_evaluator_integration_tests_snowflake_${{ github.run_number }}"
# bigquery
BIGQUERY_PROJECT: ${{ vars.BIGQUERY_PROJECT }}
BIGQUERY_SCHEMA: "dpe_integration_tests_bigquery_${{ github.run_number }}"
# redshift
REDSHIFT_HOST: ${{ vars.REDSHIFT_HOST }}
REDSHIFT_USER: ${{ vars.REDSHIFT_USER }}
REDSHIFT_DATABASE: ${{ vars.REDSHIFT_DATABASE }}
REDSHIFT_SCHEMA: "dpe_integration_tests_redshift_${{ github.run_number }}"
REDSHIFT_PORT: "5439"
# databricks
DATABRICKS_SCHEMA: "integration_tests_databricks_${{ github.run_number }}"
DATABRICKS_HOST: ${{ vars.DATABRICKS_HOST }}
DATABRICKS_HTTP_PATH: ${{ vars.DATABRICKS_HTTP_PATH }}
secrets:
SNOWFLAKE_ACCOUNT: ${{ secrets.SNOWFLAKE_ACCOUNT }}
DBT_ENV_SECRET_SNOWFLAKE_PASS: ${{ secrets.SNOWFLAKE_PASS }}
BIGQUERY_KEYFILE_JSON: ${{ secrets.BIGQUERY_KEYFILE_JSON }}
DBT_ENV_SECRET_REDSHIFT_PASS: ${{ secrets.REDSHIFT_PASS }}
DBT_ENV_SECRET_DATABRICKS_TOKEN: ${{ secrets.DBT_ENV_SECRET_DATABRICKS_TOKEN }}