Skip to content

Commit a0b9368

Browse files
committed
Use importcheck and run tests on RustPython and pypy
1 parent 93c5861 commit a0b9368

File tree

8 files changed

+69
-15
lines changed

8 files changed

+69
-15
lines changed

.github/workflows/python_ci.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ jobs:
1313
runs-on: "windows-2019"
1414
continue-on-error: ${{ matrix.config.experimental }}
1515
env:
16-
USING_COVERAGE: '3.6,3.7,3.8,3.9,3.10.0-alpha.4'
16+
USING_COVERAGE: '3.6,3.7,3.8,3.9,3.10.0-alpha.5'
1717

1818
strategy:
1919
fail-fast: False
@@ -23,7 +23,7 @@ jobs:
2323
- {python-version: "3.7", testenvs: "py37,build", experimental: False}
2424
- {python-version: "3.8", testenvs: "py38,build", experimental: False}
2525
- {python-version: "3.9", testenvs: "py39,build", experimental: False}
26-
- {python-version: "3.10.0-alpha.4", testenvs: "py310-dev,build", experimental: True}
26+
- {python-version: "3.10.0-alpha.5", testenvs: "py310-dev,build", experimental: True}
2727

2828
steps:
2929
- name: Checkout 🛎️

.github/workflows/python_ci_linux.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ jobs:
1313
runs-on: "ubuntu-20.04"
1414
continue-on-error: ${{ matrix.config.experimental }}
1515
env:
16-
USING_COVERAGE: '3.6,3.7,3.8,3.9,3.10.0-alpha.4'
16+
USING_COVERAGE: '3.6,3.7,3.8,3.9,3.10.0-alpha.5,pypy-3.6'
1717

1818
strategy:
1919
fail-fast: False
@@ -23,7 +23,8 @@ jobs:
2323
- {python-version: "3.7", testenvs: "py37,build", experimental: False}
2424
- {python-version: "3.8", testenvs: "py38,build", experimental: False}
2525
- {python-version: "3.9", testenvs: "py39,build", experimental: False}
26-
- {python-version: "3.10.0-alpha.4", testenvs: "py310-dev,build", experimental: True}
26+
- {python-version: "3.10.0-alpha.5", testenvs: "py310-dev,build", experimental: True}
27+
- {python-version: "pypy-3.6", testenvs: "pypy3,build", experimental: False}
2728

2829
steps:
2930
- name: Checkout 🛎️

.github/workflows/python_ci_macos.yml

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@ jobs:
1313
runs-on: "macos-latest"
1414
continue-on-error: ${{ matrix.config.experimental }}
1515
env:
16-
USING_COVERAGE: '3.6,3.7,3.8,3.9,3.10.0-alpha.4'
16+
USING_COVERAGE: '3.6,3.7,3.8,3.9,3.10.0-alpha.5,pypy-3.6'
1717

1818
strategy:
1919
fail-fast: False
@@ -23,7 +23,8 @@ jobs:
2323
- {python-version: "3.7", testenvs: "py37,build", experimental: False}
2424
- {python-version: "3.8", testenvs: "py38,build", experimental: False}
2525
- {python-version: "3.9", testenvs: "py39,build", experimental: False}
26-
- {python-version: "3.10.0-alpha.4", testenvs: "py310-dev,build", experimental: True}
26+
- {python-version: "3.10.0-alpha.5", testenvs: "py310-dev,build", experimental: True}
27+
- {python-version: "pypy-3.6", testenvs: "pypy3,build", experimental: False}
2728

2829
steps:
2930
- name: Checkout 🛎️
Lines changed: 43 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,43 @@
1+
# This file is managed by 'repo_helper'. Don't edit it directly.
2+
---
3+
name: RustPython
4+
5+
on:
6+
push:
7+
8+
jobs:
9+
tests:
10+
name: "ubuntu-20.04 / RustPython"
11+
runs-on: "ubuntu-20.04"
12+
env:
13+
USING_COVERAGE: 'rustpython'
14+
CARGO_TERM_COLOR: always
15+
16+
steps:
17+
- name: Checkout 🛎️
18+
uses: "actions/checkout@v2"
19+
20+
- name: Setup RustPython 🦀 🐍
21+
run: |
22+
git clone https://github.com/RustPython/RustPython
23+
cargo install --path ./RustPython
24+
rm -rf ./RustPython
25+
26+
- name: Install dependencies 🔧
27+
run: |
28+
python -VV
29+
python -m site
30+
python -m pip install --upgrade pip setuptools wheel
31+
python -m pip install --upgrade tox virtualenv
32+
33+
- name: "Run Tests for RustPython"
34+
run: python -m tox -e rustpython
35+
36+
37+
38+
- name: "Upload tempdir on failure"
39+
uses: actions/upload-artifact@v2
40+
if: failure()
41+
with:
42+
name: "pytest-tempdir"
43+
path: /tmp/pytest-of-runner/pytest-0

pyproject.toml

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,6 @@
11
[build-system]
22
requires = [ "setuptools>=40.6.0", "wheel>=0.34.2",]
33
build-backend = "setuptools.build_meta"
4+
5+
[tool.importcheck]
6+
always = ["flake8_github_actions"]

repo_helper.yml

Lines changed: 8 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -14,11 +14,13 @@ enable_tests: false
1414
enable_docs: false
1515

1616
python_versions:
17-
- 3.6
18-
- 3.7
19-
- 3.8
20-
- 3.9
17+
- '3.6'
18+
- '3.7'
19+
- '3.8'
20+
- '3.9'
2121
- 3.10-dev
22+
- pypy3
23+
- rustpython
2224

2325
additional_ignore:
2426
- action.py
@@ -29,8 +31,8 @@ keywords:
2931
- github-actions
3032

3133
entry_points:
32-
flake8.report:
33-
- github = flake8_github_actions:GitHubFormatter
34+
flake8.report:
35+
- github = flake8_github_actions:GitHubFormatter
3436

3537
classifiers:
3638
- 'Environment :: Console'

setup.cfg

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -32,6 +32,7 @@ classifiers =
3232
Programming Language :: Python :: 3.8
3333
Programming Language :: Python :: 3.9
3434
Programming Language :: Python :: Implementation :: CPython
35+
Programming Language :: Python :: Implementation :: PyPy
3536
Typing :: Typed
3637

3738
[options]

tox.ini

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,20 +13,23 @@
1313
# * pytest
1414

1515
[tox]
16-
envlist = py36, py37, py38, py39, py310-dev, mypy, build
16+
envlist = py36, py37, py38, py39, py310-dev, pypy3, rustpython, mypy, build
1717
skip_missing_interpreters = True
1818
requires =
1919
pip>=20.3.3
2020
tox-envlist>=0.1.0
2121
isolated_build = True
2222

2323
[envlists]
24-
test = py36, py37, py38, py39, py310-dev
24+
test = py36, py37, py38, py39, py310-dev, pypy3, rustpython
2525
qa = mypy, lint
2626

2727
[testenv]
2828
setenv = PYTHONDEVMODE = 1
29-
commands = python --version
29+
deps = importcheck>=0.1.0
30+
commands =
31+
python --version
32+
python -m importcheck {posargs}
3033

3134
[testenv:build]
3235
skip_install = True

0 commit comments

Comments
 (0)