unpin all deps #3
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
# This workflows will upload a Python Package using Twine when a release is created | |
# For more information see: https://help.github.com/en/actions/language-and-framework-guides/using-python-with-github-actions#publishing-to-package-registries | |
name: Test and Lint | |
on: | |
- push | |
- pull_request | |
jobs: | |
run-tests: | |
name: Unit Tests | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
version: ["3.8", "3.9", "3.10", "3.11", "3.12"] | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Start db | |
run: | | |
docker compose up --build -d | |
- name: Wait for db startup | |
uses: jakejarvis/wait-action@v0.1.1 | |
with: | |
time: '15s' | |
- name: Set up Python | |
uses: actions/setup-python@v2 | |
with: | |
python-version: ${{ matrix.version }} | |
- name: Install SQL ODBC Driver | |
run: | | |
sudo apt install unixodbc | |
sudo apt-get install unixodbc-dev | |
curl https://packages.microsoft.com/keys/microsoft.asc | sudo apt-key add - | |
echo "deb [arch=amd64] https://packages.microsoft.com/ubuntu/18.04/prod bionic main" | sudo tee /etc/apt/sources.list.d/mssql-release.list | |
sudo apt update | |
sudo ACCEPT_EULA=Y apt install msodbcsql17 | |
- name: Install Python dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install -r requirements.txt | |
- name: Run tests | |
run: | | |
python -m pytest tests --junitxml=tests.xml | |
lint: | |
name: Lint | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up Python | |
uses: actions/setup-python@v2 | |
with: | |
python-version: "3.8" | |
- name: Install Python dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install -r requirements.txt | |
- name: Lint | |
run: | | |
python -m flake8 fast_to_sql | |
type-check: | |
name: Type Check | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- name: Set up Python | |
uses: actions/setup-python@v2 | |
with: | |
python-version: "3.8" | |
- name: Install Python dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install -r requirements.txt | |
- name: Type Check | |
run: | | |
python -m pyright fast_to_sql | |