release/v0.11.0 #294
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: Run Tests | |
on: | |
push: | |
branches: [ main ] | |
paths-ignore: | |
- version.md | |
pull_request: | |
branches: [ main ] | |
workflow_dispatch: | |
workflow_call: | |
secrets: | |
TEST_SNOWFLAKE_ACCOUNT: | |
required: true | |
TEST_SNOWFLAKE_USER: | |
required: true | |
TEST_SNOWFLAKE_PASSWORD: | |
required: true | |
VAR_STORAGE_BASE_URL: | |
required: true | |
VAR_STORAGE_ROLE_ARN: | |
required: true | |
VAR_STORAGE_AWS_EXTERNAL_ID: | |
required: true | |
CODECOV_TOKEN: | |
required: true | |
jobs: | |
build: | |
runs-on: blacksmith-4vcpu-ubuntu-2204 | |
strategy: | |
fail-fast: false | |
matrix: | |
python-version: ["3.9", "3.10", "3.11"] | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: useblacksmith/setup-python@v6 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Create a virtual environment | |
run: | | |
python -m venv .venv | |
- name: Install dependencies | |
run: | | |
source ./.venv/bin/activate | |
python -m pip install --upgrade pip | |
make install-dev | |
- name: Run checks (linter, code style, static type checks, tests) | |
run: | | |
source ./.venv/bin/activate | |
ruff check titan/ | |
make typecheck | |
python -m pytest --cov=./ --cov-report=xml | |
- name: Upload coverage reports to Codecov | |
uses: codecov/codecov-action@v4 | |
env: | |
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} | |
integration: | |
runs-on: blacksmith-4vcpu-ubuntu-2204 | |
strategy: | |
fail-fast: false | |
matrix: | |
include: | |
- environment: snowflake-gcp-standard | |
edition: standard | |
- environment: snowflake-aws-standard | |
edition: standard | |
- environment: snowflake-aws-enterprise | |
edition: enterprise | |
- environment: snowflake-aws-business-critical | |
edition: enterprise | |
- environment: snowflake-azure-standard | |
edition: standard | |
environment: ${{ matrix.environment }} | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Python 3.9 | |
uses: useblacksmith/setup-python@v6 | |
with: | |
python-version: 3.9 | |
- name: Create a virtual environment | |
run: | | |
python -m venv .venv | |
- name: Install dependencies | |
run: | | |
source ./.venv/bin/activate | |
python -m pip install --upgrade pip | |
make install-dev | |
- name: Run integration tests | |
run: | | |
source ./.venv/bin/activate | |
python -m pytest --snowflake -m "standard or ${{ matrix.edition }}" --cov=./ --cov-report=xml | |
env: | |
TEST_SNOWFLAKE_ACCOUNT: ${{ secrets.TEST_SNOWFLAKE_ACCOUNT }} | |
TEST_SNOWFLAKE_USER: ${{ secrets.TEST_SNOWFLAKE_USER }} | |
TEST_SNOWFLAKE_PASSWORD: ${{ secrets.TEST_SNOWFLAKE_PASSWORD }} | |
VAR_STORAGE_BASE_URL: ${{ secrets.VAR_STORAGE_BASE_URL }} | |
VAR_STORAGE_ROLE_ARN: ${{ secrets.VAR_STORAGE_ROLE_ARN }} | |
VAR_STORAGE_AWS_EXTERNAL_ID: ${{ secrets.VAR_STORAGE_AWS_EXTERNAL_ID }} | |
TEST_SNOWFLAKE_ROLE: ACCOUNTADMIN | |
- name: Upload coverage reports to Codecov | |
uses: codecov/codecov-action@v4 | |
env: | |
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }} |