Skip to content

Commit 83fd020

Browse files
committed
Full in pyproject.toml and Poetry
1 parent 2e27988 commit 83fd020

31 files changed

+365
-509
lines changed

.github/workflows/main.yml

Lines changed: 0 additions & 110 deletions
This file was deleted.

.github/workflows/nightly.yml

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
name: Nightly tests
2+
3+
on:
4+
schedule:
5+
- cron: '1 0 * * *' # Run daily at 0:01 UTC
6+
7+
jobs:
8+
tests:
9+
if: github.repository_owner == 'pytest-dev'
10+
uses: ./.github/workflows/test.yml

.github/workflows/publish.yml

Lines changed: 34 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,34 @@
1+
name: publish
2+
3+
on:
4+
push:
5+
tags:
6+
- v*
7+
8+
jobs:
9+
publish:
10+
runs-on: ubuntu-latest
11+
steps:
12+
- uses: actions/checkout@v3
13+
- name: Set up Python
14+
uses: actions/setup-python@v3
15+
with:
16+
python-version: "3.9"
17+
- name: Install poetry
18+
run: curl -sSL https://install.python-poetry.org | python3 -
19+
- name: Configure poetry
20+
run: poetry config virtualenvs.in-project true
21+
- name: Set up cache
22+
uses: actions/cache@v3
23+
with:
24+
path: .venv
25+
key: venv-${{ hashFiles('**/poetry.lock') }}
26+
restore-keys: venv-
27+
- name: Install Dependencies
28+
run: poetry install
29+
- name: Publish
30+
run: >-
31+
poetry publish
32+
--build
33+
--username __token__
34+
--password ${{ secrets.PYPI_TOKEN }}

.github/workflows/test.yml

Lines changed: 88 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,88 @@
1+
name: test
2+
3+
on:
4+
push:
5+
branches:
6+
- master
7+
tags-ignore:
8+
- v*
9+
pull_request:
10+
workflow_call:
11+
12+
env:
13+
PYTEST_ADDOPTS: "-m 'not (edge or safari)'"
14+
15+
jobs:
16+
test:
17+
runs-on: ${{ matrix.os }}
18+
strategy:
19+
fail-fast: false
20+
matrix:
21+
python: ["3.6", "3.7", "3.8", "3.9", "3.10", "pypy-3.8"]
22+
os: [ubuntu-latest, windows-latest]
23+
include:
24+
- python: "3.7"
25+
tox_env: "py37"
26+
- python: "3.8"
27+
tox_env: "py38"
28+
- python: "3.9"
29+
tox_env: "py39"
30+
- python: "3.10"
31+
tox_env: "py310"
32+
- python: "pypy-3.8"
33+
tox_env: "pypy3"
34+
steps:
35+
- uses: actions/checkout@v3
36+
37+
- name: Set up Python
38+
uses: actions/setup-python@v3
39+
with:
40+
python-version: ${{ matrix.python }}
41+
42+
- name: Install tox
43+
run: |
44+
python -m pip install --upgrade pip
45+
pip install tox
46+
47+
- name: Setup Firefox
48+
uses: browser-actions/setup-firefox@latest
49+
with:
50+
firefox-version: latest
51+
52+
- name: Setup Geckodriver
53+
uses: browser-actions/setup-geckodriver@latest
54+
55+
- name: Setup Chrome
56+
uses: browser-actions/setup-chrome@latest
57+
with:
58+
chrome-version: stable
59+
60+
- name: Setup Chromedriver
61+
uses: nanasess/setup-chromedriver@master
62+
63+
- name: Cache tox environments
64+
uses: actions/cache@v3
65+
with:
66+
path: .tox
67+
key: tox-${{ matrix.os }}-${{ matrix.python }}-${{ hashFiles('pyproject.toml', 'poetry.lock') }}
68+
69+
- name: Test
70+
run: tox -e ${{ matrix.tox_env }}
71+
72+
docs:
73+
runs-on: ubuntu-latest
74+
steps:
75+
- uses: actions/checkout@v3
76+
77+
- name: Set up Python
78+
uses: actions/setup-python@v3
79+
with:
80+
python-version: 3.9
81+
82+
- name: Install dependencies
83+
run: |
84+
python -m pip install --upgrade pip
85+
pip install tox
86+
87+
- name: Run tests
88+
run: "tox -e docs"

.pre-commit-config.yaml

Lines changed: 12 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,15 +1,20 @@
11
repos:
2-
3-
- repo: https://github.com/psf/black
4-
rev: stable
2+
- repo: https://github.com/psf/black
3+
rev: 22.1.0
54
hooks:
6-
- id: black
5+
- id: black
76
args: [--safe, --quiet]
87
language_version: python3
98

10-
- repo: https://gitlab.com/pycqa/flake8
11-
rev: 3.7.7
9+
- repo: https://github.com/pre-commit/pre-commit-hooks
10+
rev: v4.1.0
11+
hooks:
12+
- id: trailing-whitespace
13+
- id: end-of-file-fixer
14+
15+
- repo: https://gitlab.com/PyCQA/flake8
16+
rev: 4.0.1
1217
hooks:
13-
- id: flake8
18+
- id: flake8
1419
exclude: docs
1520
language_version: python3

Pipfile

Lines changed: 0 additions & 17 deletions
This file was deleted.

old-ci.yml

Lines changed: 0 additions & 81 deletions
This file was deleted.

0 commit comments

Comments
 (0)