Skip to content

Commit 74957ca

Browse files
authored
Merge pull request #519 from nipype/CI/tests_updates
updating test pydra GA
2 parents bf8d6e8 + 5bbca75 commit 74957ca

File tree

5 files changed

+26
-28
lines changed

5 files changed

+26
-28
lines changed

.github/workflows/testpydra.yml

Lines changed: 11 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,11 @@
11
name: Pydra
22

3-
on: [push, pull_request]
3+
on:
4+
push:
5+
branches:
6+
- master
7+
pull_request:
8+
49

510
defaults:
611
run:
@@ -11,8 +16,7 @@ jobs:
1116
strategy:
1217
matrix:
1318
os: [macos-latest, ubuntu-latest, windows-latest]
14-
python-version: [3.7, 3.8, 3.9]
15-
install: [install, develop, wheel]
19+
python-version: [3.7, 3.8, 3.9, "3.10"]
1620
fail-fast: false
1721
runs-on: ${{ matrix.os }}
1822

@@ -26,27 +30,13 @@ jobs:
2630
with:
2731
python-version: ${{ matrix.python-version }}
2832
- name: Update build tools
29-
run: python -m pip install --upgrade pip setuptools
30-
31-
32-
- name: Install Pydra tests dependencies (develop or setup.py install)
33-
if: matrix.install == 'develop' || matrix.install == 'install'
34-
run: pip install ".[test]"
35-
36-
37-
- name: Install dependencies (setup.py install)
38-
if: matrix.install == 'install'
39-
run: python setup.py install
33+
run: python -m pip install --upgrade pip build
4034

41-
- name: Install dependencies (wheel)
42-
if: matrix.install == 'wheel'
43-
run: |
44-
python setup.py bdist_wheel
45-
pip install dist/*.whl
35+
- name: Build pydra
36+
run: python -m build
4637

4738

48-
- name: Install Pydra tests dependencies (wheel)
49-
if: matrix.install == 'wheel'
39+
- name: Install Pydra tests dependencies
5040
run: pip install "$( ls dist/pydra*.whl )[test]"
5141

5242

.github/workflows/testsingularity.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,14 +1,18 @@
11
name: Singularity
22

3-
on: [push, pull_request]
3+
on:
4+
push:
5+
branches:
6+
- master
7+
pull_request:
48

59
jobs:
610
build:
711
name: Build
812
runs-on: ubuntu-latest
913
strategy:
1014
matrix:
11-
python-version: [3.7, 3.8, 3.9]
15+
python-version: [3.7, 3.8, 3.9, "3.10"]
1216
fail-fast: False
1317

1418
steps:

.github/workflows/testslurm.yml

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,10 @@
11
name: SLURM
22

3-
on: [push, pull_request]
3+
on:
4+
push:
5+
branches:
6+
- master
7+
pull_request:
48

59
jobs:
610
build:

pydra/engine/task.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -159,8 +159,8 @@ def __init__(
159159
return_info = func.__annotations__["return"]
160160
# e.g. python annotation: fun() -> ty.NamedTuple("Output", [("out", float)])
161161
# or pydra decorator: @pydra.mark.annotate({"return": ty.NamedTuple(...)})
162-
if hasattr(return_info, "__name__") and hasattr(
163-
return_info, "__annotations__"
162+
if hasattr(return_info, "__name__") and getattr(
163+
return_info, "__annotations__", None
164164
):
165165
name = return_info.__name__
166166
fields = list(return_info.__annotations__.items())

setup.cfg

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,7 @@ install_requires =
3030
etelemetry >= 0.2.2
3131

3232
test_requires =
33-
pytest >= 4.4.0, < 6.0.0
33+
pytest >= 6.2.5
3434
pytest-cov
3535
pytest-env
3636
pytest-xdist < 2.0
@@ -64,7 +64,7 @@ doc =
6464
docs =
6565
%(doc)s
6666
test =
67-
pytest >= 4.4.0, < 6.0.0
67+
pytest >= 6.2.5
6868
pytest-cov
6969
pytest-env
7070
pytest-xdist < 2.0

0 commit comments

Comments
 (0)