Skip to content

Regression Suite

Regression Suite #3919

# This is the main regression test script which tests the entire application.
# Other GitHub Actions test subsets primarily to ensure compatibility for different OSes.
# This script is run on Ubuntu, the most common OS for CI/CD pipelines.
# The script is run on Python 3.10, 3.11, and 3.12.
# The script is run at 4:00 AM UTC every day and on every push to the repository.
name: Regression Suite
on:
push:
schedule:
- cron: "0 4 * * *"
jobs:
regression_matrix:
strategy:
max-parallel: 4
fail-fast: false
matrix:
python-version: ['3.10', '3.11', '3.12']
os: [ubuntu-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout code
uses: actions/checkout@v4
- name: Set up Python ${{ matrix.python-version }} x64
if: matrix.os == 'ubuntu-latest'
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
architecture: x64
- name: Install Requirements
run: |
python -m pip install --upgrade pip
python -m pip install --upgrade numpy cython
python -m pip install --upgrade -r $GITHUB_WORKSPACE/requirements.txt
python -m pip install --upgrade -r $GITHUB_WORKSPACE/tests/requirements.txt
python setup.py build_ext --inplace
- name: "Start Memcached Instance"
run: |
docker run -d --name my-memcached \
-p 11211:11211 \
memcached \
-m 16
- name: "Authenticate to Google Cloud"
uses: google-github-actions/auth@v1
with:
credentials_json: '${{ secrets.GCP_KEY }}'
- name: Decode Astra (DataStax/Cassandra) Secure Connect Bundle
run: |
echo "${{ secrets.ASTRA_SECURE_BUNDLE_BASE64 }}" | base64 -d > secure-connect.zip
- name: Run Regression Tests
run: python -m coverage run -m pytest --color=yes
env:
AZURE_STORAGE_CONNECTION_STRING: "DefaultEndpointsProtocol=http;AccountName=devstoreaccount1;AccountKey=Eby8vdM02xNOcqFlqUwJPLlmEtlCDXJ1OUzFT50uSRZ6IFsuFq2UVErCz4I6tq/K1SZFPTOtr/KBHBeksoGMGw==;BlobEndpoint=http://127.0.0.1:10000/devstoreaccount1;QueueEndpoint=http://127.0.0.1:10001/devstoreaccount1;"
MINIO_END_POINT: "s3.eu-west-2.amazonaws.com"
GCP_PROJECT_ID: mabeldev
MYSQL_USER: '${{ secrets.MYSQL_USER }}'
MYSQL_PASSWORD: '${{ secrets.MYSQL_PASSWORD }}'
POSTGRES_USER: '${{ secrets.POSTGRES_USER }}'
POSTGRES_PASSWORD: '${{ secrets.POSTGRES_PASSWORD }}'
MONGODB_CONNECTION: '${{ secrets.MONGODB_CONNECTION }}'
MONGODB_DATABASE: opteryx
COCKROACH_USER: '${{ secrets.COCKROACH_USER }}'
COCKROACH_PASSWORD: '${{ secrets.COCKROACH_PASSWORD }}'
REDIS_CONNECTION: '${{ secrets.REDIS_CONNECTION }}'
MEMCACHED_SERVER: 'localhost:11211'
DATASTAX_CLIENT_ID: '${{ secrets.DATASTAX_CLIENT_ID }}'
DATASTAX_CLIENT_SECRET: '${{ secrets.DATASTAX_CLIENT_SECRET }}'
OPTERYX_DEBUG: 1
MAX_LOCAL_BUFFER_CAPACITY: 100
MAX_CACHE_EVICTIONS_PER_QUERY: 4
DATA_CATALOG_PROVIDER: 'TARCHIA'
DATA_CATALOG_CONFIGURATION: '${{ secrets.DATA_CATALOG_CONFIGURATION }}'
TARCHIA_KEY: '${{ secrets.TARCHIA_KEY }}'
VALKEY_CONNECTION: '${{ secrets.VALKEY_CONFIG }}'
- name: Check Coverage
run: python -m coverage report --include=opteryx/** --fail-under=90 -m
- name: "Upload coverage to Codecov"
if: matrix.os == 'ubuntu-latest' && matrix.python-version == '3.10'
uses: codecov/codecov-action@v1
with:
fail_ci_if_error: false