Skip to content

upgrade azure-kusto-data #329

upgrade azure-kusto-data

upgrade azure-kusto-data #329

Workflow file for this run

# This workflow will install Python dependencies, run tests and lint with a single version of Python
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-python-with-github-actions
name: Run tests
on:
push:
branches: [ master, release ]
pull_request:
branches: [ master ]
jobs:
build:
runs-on: ubuntu-latest
timeout-minutes: 1
strategy:
matrix:
python-version: [ '3.7', '3.8', '3.9' ] # Make sure this matches the supported versions in setup.py
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
# According to the internet using 'python -m pip' instead of 'pip' can prevent some issues
run: |
python -m pip install --upgrade pip
# For some reason transitive dependencies are not installed properly, unless we first explicitly install 'azure-kusto-data'. Hence this ugly hack.
python -m pip install `grep -oP "azure-kusto-data==[^']+" setup.py`
python -m pip install .[test]
python -m pip freeze
- name: Lint with flake8
run: |
python -m pip install flake8
python -m flake8 setup.py pykusto test --count --max-complexity=10 --max-line-length=180 --show-source --statistics
- name: Test with pytest
run: |
python -m pip install pytest pytest-cov
python -m pytest --cov=pykusto --cov-report term-missing --cov-fail-under=100