diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml new file mode 100644 index 0000000..893bfdc --- /dev/null +++ b/.github/workflows/test.yml @@ -0,0 +1,34 @@ +name: Tests + +on: + - push + - pull_request + - workflow_dispatch + +jobs: + test: + runs-on: ${{ matrix.os }} + strategy: + matrix: + os: [ubuntu-latest, windows-latest, macos-latest] + python-version: ["3.9", "3.10", "3.11"] + steps: + - name: Checkout repository + uses: actions/checkout@v3 + - name: Set up Python ${{ matrix.python-version }} + uses: actions/setup-python@v2 + with: + python-version: ${{ matrix.python-version }} + - name: Install dependencies + run: | + python -m pip install --upgrade pip + pip install -r requirements_dev.txt + pip install -r requirements.txt + - name: Run tests + run: python -m pytest --junitxml=pytest.xml + + - name: Upload a Test Results file + uses: actions/upload-artifact@v3.1.2 + with: + name: test-results + path: ${{ github.workspace }}/pytest.xml diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 7ccd391..4fafbdf 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -15,7 +15,7 @@ repos: - id: black - repo: https://github.com/pycqa/isort - rev: 5.10.1 + rev: 5.12.0 hooks: - id: isort name: isort (python) diff --git a/requirements_dev.txt b/requirements_dev.txt index 35df800..31b3b69 100644 --- a/requirements_dev.txt +++ b/requirements_dev.txt @@ -1,4 +1,4 @@ -pip==21.1 +pip==23.2 bump2version==0.5.11 wheel==0.38.1 watchdog==0.9.0 @@ -7,5 +7,5 @@ tox==3.14.0 coverage==4.5.4 Sphinx==1.8.5 twine==1.14.0 -pytest==6.2.4 +pytest==7.4.0 black==21.7b0