Use different style for GHA cache key. #914
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: 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: | |
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 }} | |
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 }} | |
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 }} | |
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 }} | |
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 }} | |
slack-failure: | |
environment: DW_INTEGRATION_TESTS | |
needs: [snowflake-tests, redshift-tests, bigquery-tests] | |
if: ${{ github.event_name != 'pull_request' && failure() }} | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Slack Failure | |
uses: kpritam/slack-job-status-action@v1 | |
with: | |
job-status: Failure | |
slack-bot-token: ${{ secrets.SLACK_BOT_TOKEN }} | |
channel: ${{ secrets.MF_BUG_SINK }} |