Skip to content

fix: automation

fix: automation #677

Workflow file for this run

name: Main Workflow
on:
push:
schedule:
- cron: "0 0 * * 0"
jobs:
build:
name: Build
timeout-minutes: 10
strategy:
matrix:
python-version: [
2.7,
3.5,
3.6,
3.7,
3.8,
3.9,
"3.10",
"3.11",
"3.12",
latest,
rc
]
mongodb-version: ["6.0", "7.0"]
adapter: ["tiny", "mongo"]
runs-on: ubuntu-latest
container: python:${{ matrix.python-version }}
steps:
- uses: actions/checkout@v4
- uses: supercharge/mongodb-github-action@1.11.0
with:
mongodb-version: ${{ matrix.mongodb-version }}
if: matrix.adapter == 'mongo'
- run: python --version
- run: |
pip install -r requirements.txt
pip install -r extra.txt
if: matrix.python-version != '2.7'
- run: |
pip install -r requirements.py2.txt
pip install -r extra.py2.txt
if: matrix.python-version == '2.7'
- run: |
pip install black
black . --check
if: matrix.python-version == '3.12'
- run: |
pip install pytest
ADAPTER=${{ matrix.adapter }} HTTPBIN=httpbin.bemisc.com pytest
- run: ADAPTER=${{ matrix.adapter }} HTTPBIN=httpbin.bemisc.com python setup.py test
if: matrix.python-version != '3.12' && matrix.python-version != 'latest'
build-pypy:
name: Build PyPy
timeout-minutes: 10
strategy:
matrix:
python-version: [2.7, 3.6, 3.9, "3.10"]
mongodb-version: ["6.0", "7.0"]
adapter: ["tiny", "mongo"]
runs-on: ubuntu-latest
container: pypy:${{ matrix.python-version }}
steps:
- uses: actions/checkout@v4
- uses: supercharge/mongodb-github-action@1.11.0
with:
mongodb-version: ${{ matrix.mongodb-version }}
if: matrix.adapter == 'mongo'
- run: pypy --version
- run: |
pip install -r requirements.txt
pip install -r extra.txt
if: matrix.python-version != '2.7'
- run: |
pip install -r requirements.py2.txt
pip install -r extra.py2.txt
if: matrix.python-version == '2.7'
- run: |
pip install black
black . --check
if: matrix.python-version == '3.12'
- run: |
pip install pytest
ADAPTER=${{ matrix.adapter }} HTTPBIN=httpbin.bemisc.com pytest
- run: ADAPTER=${{ matrix.adapter }} HTTPBIN=httpbin.bemisc.com pypy setup.py test
if: matrix.python-version != '3.12' && matrix.python-version != 'latest'