Skip to content

Merge remote-tracking branch 'buildbot/3.9.x' into dne_master #4

Merge remote-tracking branch 'buildbot/3.9.x' into dne_master

Merge remote-tracking branch 'buildbot/3.9.x' into dne_master #4

Workflow file for this run

name: CI
on:
push:
branches:
- master
pull_request:
permissions:
contents: read
jobs:
db:
name: DB / ${{ matrix.name }}
runs-on: ubuntu-20.04
strategy:
fail-fast: false
matrix:
include:
- name: MySQL 5
database: mysql:5
connection: 'mysql+mysqldb://buildbot:[email protected]:3306/bbtest?storage_engine=InnoDB'
check: mysqladmin ping
- name: MySQL latest
database: mysql:latest
connection: 'mysql+mysqldb://buildbot:[email protected]:3306/bbtest?storage_engine=InnoDB'
check: mysqladmin ping
- name: PostgreSQL 9 / psycopg2
database: postgres:9
connection: 'postgresql+psycopg2://buildbot:[email protected]:5432/bbtest'
check: pg_isready
- name: PostgreSQL 9 / pg8000
database: postgres:9
connection: 'postgresql+pg8000://buildbot:[email protected]:5432/bbtest'
check: pg_isready
- name: PostgreSQL latest / psycopg2
database: postgres:latest
connection: 'postgresql+psycopg2://buildbot:[email protected]:5432/bbtest'
check: pg_isready
- name: PostgreSQL latest / pg8000
database: postgres:latest
connection: 'postgresql+pg8000://buildbot:[email protected]:5432/bbtest'
check: pg_isready
env:
BUILDBOT_TEST_DB_URL: ${{ matrix.connection }}
services:
database:
image: ${{ matrix.database }}
env:
MYSQL_USER: buildbot
MYSQL_PASSWORD: buildbot
MYSQL_DATABASE: bbtest
MYSQL_ALLOW_EMPTY_PASSWORD: yes
POSTGRES_USER: buildbot
POSTGRES_PASSWORD: buildbot
POSTGRES_DB: bbtest
ports:
- '3306:3306'
- '5432:5432'
options: --health-cmd "${{ matrix.check }}" --health-interval 10s --health-timeout 5s --health-retries 10
steps:
- uses: actions/checkout@v2
- run: sudo apt-get install aspell aspell-en enchant iamerican ispell
- name: Set up Python
uses: actions/setup-python@v2
with:
python-version: 3.8
- name: Cache pip
uses: actions/cache@v2
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('requirements-ci.txt', 'requirements-cidb.txt') }}
restore-keys: ${{ runner.os }}-pip-
- run: pip install -U pip wheel
- run: pip install -r requirements-ci.txt -r requirements-cidb.txt
# run real db tests under coverage to have several merging coverage report
# https://github.com/codecov/support/wiki/Merging-Reports
- run: coverage run --rcfile=.coveragerc $(which trial) --reporter=text --rterrors buildbot.test buildbot_worker.test
- run: |
curl -Os https://uploader.codecov.io/v0.4.1/linux/codecov
echo "32cb14b5f3aaacd67f4c1ff55d82f037d3cd10c8e7b69c051f27391d2e66e15c codecov" | sha256sum --check
chmod +x ./codecov
CODECOV_TOKEN="b80c80d7-689d-46d7-b1aa-59168bb4c9a9" ./codecov
win:
name: Win / python ${{ matrix.python-version }}
runs-on: windows-2019
strategy:
matrix:
python-version: ["3.8", "3.9", "3.10", "3.11"]
steps:
- uses: "actions/checkout@v2"
- uses: "actions/setup-python@v2"
with:
python-version: "${{ matrix.python-version }}"
- name: "Install dependencies"
run: |
python -c "import sys; print(sys.prefix)"
python -c "import sys; print(sys.exec_prefix)"
python -c "import sys; print(sys.executable)"
python -V -V
python -m pip install -U pip setuptools wheel
python -m pip install -r requirements-ci.txt
python -m pip list
# Check that pywin32 is properly installed
python -c "import win32api"
- name: "Run tests for ${{ matrix.python-version }}"
run: "python -m twisted.trial --reporter=text --rterrors buildbot.test buildbot_worker.test"