-
Notifications
You must be signed in to change notification settings - Fork 96
111 lines (100 loc) · 4.3 KB
/
cd-sql-engine-tests.yaml
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
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
name: MetricFlow SQL Engine Tests
# Runs tests against the other SQL engines that are supported. These engines are hosted externally, and tend to be
# slower. As the test will be I/O bound, the tests can be run with higher parallelism to get faster runtimes.
on:
workflow_dispatch:
push:
branches:
- main
pull_request:
types: [labeled]
env:
PYTHON_VERSION: "3.8"
EXTERNAL_ENGINE_TEST_PARALLELISM: 8
ADDITIONAL_PYTEST_OPTIONS: "--use-persistent-source-schema"
jobs:
snowflake-tests:
environment: DW_INTEGRATION_TESTS
if: ${{ github.event.action != 'labeled' || github.event.label.name == 'run_mf_sql_engine_tests' }}
name: Snowflake Tests
runs-on: ubuntu-latest
steps:
- name: Check-out the repo
uses: actions/checkout@v3
- name: Test w/ Python ${{ env.PYTHON_VERSION }}
uses: ./.github/actions/run-mf-tests
with:
python-version: ${{ env.PYTHON_VERSION }}
mf_sql_engine_url: ${{ secrets.MF_SNOWFLAKE_URL }}
mf_sql_engine_password: ${{ secrets.MF_SNOWFLAKE_PWD }}
parallelism: ${{ env.EXTERNAL_ENGINE_TEST_PARALLELISM }}
additional-pytest-options: ${{ env.ADDITIONAL_PYTEST_OPTIONS }}
make-target: "test-snowflake"
redshift-tests:
environment: DW_INTEGRATION_TESTS
name: Redshift Tests
if: ${{ github.event.action != 'labeled' || github.event.label.name == 'run_mf_sql_engine_tests' }}
runs-on: ubuntu-latest
steps:
- name: Check-out the repo
uses: actions/checkout@v3
- name: Test w/ Python ${{ env.PYTHON_VERSION }}
uses: ./.github/actions/run-mf-tests
with:
python-version: ${{ env.PYTHON_VERSION }}
mf_sql_engine_url: ${{ secrets.MF_REDSHIFT_URL }}
mf_sql_engine_password: ${{ secrets.MF_REDSHIFT_PWD }}
parallelism: ${{ env.EXTERNAL_ENGINE_TEST_PARALLELISM }}
additional-pytest-options: ${{ env.ADDITIONAL_PYTEST_OPTIONS }}
make-target: "test-redshift"
bigquery-tests:
environment: DW_INTEGRATION_TESTS
name: BigQuery Tests
if: ${{ github.event.action != 'labeled' || github.event.label.name == 'run_mf_sql_engine_tests' }}
runs-on: ubuntu-latest
steps:
- name: Check-out the repo
uses: actions/checkout@v3
- name: Test w/ Python ${{ env.PYTHON_VERSION }}
uses: ./.github/actions/run-mf-tests
with:
python-version: ${{ env.PYTHON_VERSION }}
MF_SQL_ENGINE_URL: ${{ secrets.MF_BIGQUERY_URL }}
MF_SQL_ENGINE_PASSWORD: ${{ secrets.MF_BIGQUERY_PWD }}
parallelism: ${{ env.EXTERNAL_ENGINE_TEST_PARALLELISM }}
additional-pytest-options: ${{ env.ADDITIONAL_PYTEST_OPTIONS }}
make-target: "test-bigquery"
databricks-cluster-tests:
environment: DW_INTEGRATION_TESTS
name: Databricks Cluster Tests
if: ${{ github.event.action != 'labeled' || github.event.label.name == 'run_mf_sql_engine_tests' }}
runs-on: ubuntu-latest
steps:
- name: Check-out the repo
uses: actions/checkout@v3
- name: Test w/ Python Python ${{ env.PYTHON_VERSION }}
uses: ./.github/actions/run-mf-tests
with:
python-version: ${{ env.PYTHON_VERSION }}
mf_sql_engine_url: ${{ secrets.MF_DATABRICKS_CLUSTER_URL }}
mf_sql_engine_password: ${{ secrets.MF_DATABRICKS_PWD }}
parallelism: ${{ env.EXTERNAL_ENGINE_TEST_PARALLELISM }}
additional-pytest-options: ${{ env.ADDITIONAL_PYTEST_OPTIONS }}
make-target: "test-databricks"
databricks-sql-warehouse-tests:
environment: DW_INTEGRATION_TESTS
name: Databricks SQL Warehouse Tests
if: ${{ github.event.action != 'labeled' || github.event.label.name == 'run_mf_sql_engine_tests' }}
runs-on: ubuntu-latest
steps:
- name: Check-out the repo
uses: actions/checkout@v3
- name: Test w/ Python ${{ env.PYTHON_VERSION }}
uses: ./.github/actions/run-mf-tests
with:
python-version: ${{ env.PYTHON_VERSION }}
mf_sql_engine_url: ${{ secrets.MF_DATABRICKS_SQL_WAREHOUSE_URL }}
mf_sql_engine_password: ${{ secrets.MF_DATABRICKS_PWD }}
parallelism: ${{ env.EXTERNAL_ENGINE_TEST_PARALLELISM }}
additional-pytest-options: ${{ env.ADDITIONAL_PYTEST_OPTIONS }}
make-target: "test-databricks"