Skip to content

Commit 829ac0d

Browse files
authored
Merge pull request #33 from VirtualPlanetaryLaboratory/comprehensive-testing
Restored full matrix of OS and Python versions.
2 parents ae75aee + fd51531 commit 829ac0d

File tree

19 files changed

+57
-57
lines changed

19 files changed

+57
-57
lines changed

.github/workflows/pip-install.yml

Lines changed: 16 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -8,27 +8,28 @@ on:
88
jobs:
99

1010
build:
11-
name: Build wheels on ${{ matrix.os }}
11+
name: 'py${{ matrix.python }} on ${{ matrix.os }}'
1212
runs-on: ${{ matrix.os }}
1313
strategy:
1414
matrix:
15-
os: [ubuntu-latest, macos-latest]
16-
python: ['3.7', '3.8', '3.9']
15+
os: [macos-15-intel, macos-26, ubuntu-22.04, ubuntu-24.04]
16+
python: ['3.9', '3.10', '3.11', '3.12', '3.13', '3.14']
1717
steps:
18-
- uses: actions/checkout@v3
18+
- uses: actions/checkout@v4
1919
with:
2020
submodules: true
2121
fetch-depth: 0
2222

23-
- uses: actions/setup-python@v4
23+
- uses: actions/setup-python@v5
2424
name: Install Python
2525
with:
2626
python-version: ${{ matrix.python }}
27+
allow-prereleases: true
2728

2829
- name: Build
2930
run: |
30-
python -m pip install -U pip pep517 twine setuptools_scm astropy
31-
python -m pep517.build .
31+
python -m pip install -U pip build twine setuptools setuptools_scm wheel
32+
python -m build
3233
3334
- name: Test the sdist
3435
run: |
@@ -42,21 +43,22 @@ jobs:
4243
venv-wheel/bin/python -m pip install dist/vspace*.whl
4344
venv-wheel/bin/python -c "import vspace; print(vspace.__version__)"
4445
45-
- uses: actions/upload-artifact@v3
46+
- uses: actions/upload-artifact@v4
4647
with:
48+
name: dist-${{ matrix.os }}-${{ matrix.python }}
4749
path: dist/*
4850

4951
upload_pypi:
5052
needs: [build]
5153
runs-on: ubuntu-latest
5254
if: github.event_name == 'release' && github.event.action == 'published'
55+
permissions:
56+
id-token: write
5357
steps:
54-
- uses: actions/download-artifact@v3
58+
- uses: actions/download-artifact@v4
5559
with:
56-
name: artifact
60+
pattern: dist-*
5761
path: dist
62+
merge-multiple: true
5863

59-
- uses: pypa/gh-action-pypi-publish@master
60-
with:
61-
user: __token__
62-
password: ${{ secrets.pypi_password }}
64+
- uses: pypa/gh-action-pypi-publish@release/v1

.github/workflows/tests.yml

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,8 +1,6 @@
11
name: tests
22

33
on:
4-
push:
5-
branches: [main]
64
pull_request:
75
branches: [main]
86

@@ -13,8 +11,8 @@ jobs:
1311
strategy:
1412
fail-fast: false
1513
matrix:
16-
os: [ubuntu-22.04]
17-
python-version: ["3.9"]
14+
os: [ubuntu-22.04, ubuntu-24.04, macos-15-intel, macos-latest]
15+
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13", "3.14"]
1816

1917
steps:
2018
- uses: actions/checkout@v5

README.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -11,17 +11,17 @@
1111
<a href="LICENSE"><img src="https://img.shields.io/badge/license-MIT-purple.svg"></a>
1212
<a href="https://VirtualPlanetaryLaboratory.github.io/vplanet/conduct.html"><img src="https://img.shields.io/badge/Code%20of-Conduct-7d93c7.svg"></a>
1313
<br>
14-
<img src="https://img.shields.io/badge/Unit%20Tests-46-darkblue.svg"></a>
14+
<img src="https://img.shields.io/badge/Unit%20Tests-48-darkblue.svg"></a>
1515
<a href="https://github.com/VirtualPlanetaryLaboratory/vspace/actions/workflows/tests.yml">
1616
<img src="https://github.com/VirtualPlanetaryLaboratory/vspace/actions/workflows/tests.yml/badge.svg">
17-
<img src="https://img.shields.io/badge/Python-3.9--3.13-orange.svg"></a>
17+
<img src="https://img.shields.io/badge/Python-3.9--3.14-orange.svg"></a>
1818
<a href="https://github.com/VirtualPlanetaryLaboratory/vspace/actions/workflows/pip-install.yml">
1919
<a href="https://codecov.io/github/VirtualPlanetaryLaboratory/vspace">
2020
<img src="https://codecov.io/github/VirtualPlanetaryLaboratory/vspace/graph/badge.svg?token=6Z8HVQW8N6">
2121
</a>
2222
<br>
2323
<img src="https://github.com/VirtualPlanetaryLaboratory/vspace/actions/workflows/pip-install.yml/badge.svg">
24-
<img src="https://img.shields.io/badge/Python-3.6--3.9-orange.svg"></a>
24+
<img src="https://img.shields.io/badge/Python-3.9--3.14-orange.svg"></a>
2525
<img src = "https://img.shields.io/badge/Platforms-Linux_|%20macOS-darkgreen.svg?style=flat">
2626
</a>
2727
</p>

tests/FileOps/test_file_operations.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,7 @@ def test_multiple_input_files():
2323
shutil.rmtree(dir)
2424

2525
# Run vspace with earth.in and sun.in
26-
subprocess.check_output(["vspace", "vspace_multifile.in"], cwd=path)
26+
subprocess.check_output(["vspace", "-f", "vspace_multifile.in"], cwd=path)
2727

2828
# Grab the output folders
2929
folders = sorted([f.path for f in os.scandir(dir) if f.is_dir()])
@@ -70,7 +70,7 @@ def test_option_addition():
7070
if dir.exists():
7171
shutil.rmtree(dir)
7272

73-
subprocess.check_output(["vspace", "vspace_option_add.in"], cwd=path)
73+
subprocess.check_output(["vspace", "-f", "vspace_option_add.in"], cwd=path)
7474

7575
folders = sorted([f.path for f in os.scandir(dir) if f.is_dir()])
7676

@@ -106,7 +106,7 @@ def test_option_replacement():
106106
if dir.exists():
107107
shutil.rmtree(dir)
108108

109-
subprocess.check_output(["vspace", "vspace_option_replace.in"], cwd=path)
109+
subprocess.check_output(["vspace", "-f", "vspace_option_replace.in"], cwd=path)
110110

111111
folders = sorted([f.path for f in os.scandir(dir) if f.is_dir()])
112112
assert len(folders) == 2, "Should have 2 trials"
@@ -163,7 +163,7 @@ def test_source_folder_with_tilde():
163163
shutil.rmtree(dir)
164164

165165
# Run vspace
166-
subprocess.check_output(["vspace", "vspace_tilde_test.in"], cwd=path)
166+
subprocess.check_output(["vspace", "-f", "vspace_tilde_test.in"], cwd=path)
167167

168168
# Verify it worked
169169
folders = sorted([f.path for f in os.scandir(dir) if f.is_dir()])

tests/GridMode/test_multi_parameter.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ def test_two_parameters_cartesian_product():
2424
shutil.rmtree(dir)
2525

2626
# Run vspace
27-
subprocess.check_output(["vspace", "vspace_two_param.in"], cwd=path)
27+
subprocess.check_output(["vspace", "-f", "vspace_two_param.in"], cwd=path)
2828

2929
# Grab the output folders
3030
folders = sorted([f.path for f in os.scandir(dir) if f.is_dir()])
@@ -97,7 +97,7 @@ def test_three_parameters_cube():
9797
if dir.exists():
9898
shutil.rmtree(dir)
9999

100-
subprocess.check_output(["vspace", "vspace_three_param.in"], cwd=path)
100+
subprocess.check_output(["vspace", "-f", "vspace_three_param.in"], cwd=path)
101101

102102
folders = sorted([f.path for f in os.scandir(dir) if f.is_dir()])
103103

@@ -163,7 +163,7 @@ def test_mixed_spacing_types():
163163
if dir.exists():
164164
shutil.rmtree(dir)
165165

166-
subprocess.check_output(["vspace", "vspace_mixed_spacing.in"], cwd=path)
166+
subprocess.check_output(["vspace", "-f", "vspace_mixed_spacing.in"], cwd=path)
167167

168168
folders = sorted([f.path for f in os.scandir(dir) if f.is_dir()])
169169

tests/Random/test_cosine.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ def test_cosine_degrees():
2626
shutil.rmtree(dir)
2727

2828
# Run vspace with fixed seed for reproducibility
29-
subprocess.check_output(["vspace", "vspace_cosine_deg.in"], cwd=path)
29+
subprocess.check_output(["vspace", "-f", "vspace_cosine_deg.in"], cwd=path)
3030

3131
# Grab the output folders
3232
folders = sorted([f.path for f in os.scandir(dir) if f.is_dir()])
@@ -87,7 +87,7 @@ def test_cosine_radians():
8787
if dir.exists():
8888
shutil.rmtree(dir)
8989

90-
subprocess.check_output(["vspace", "vspace_cosine_rad.in"], cwd=path)
90+
subprocess.check_output(["vspace", "-f", "vspace_cosine_rad.in"], cwd=path)
9191

9292
folders = sorted([f.path for f in os.scandir(dir) if f.is_dir()])
9393
angles = []

tests/Random/test_gaussian.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,7 @@ def test_gaussian_basic():
2626
shutil.rmtree(dir)
2727

2828
# Run vspace with fixed seed for reproducibility
29-
subprocess.check_output(["vspace", "vspace_gaussian.in"], cwd=path)
29+
subprocess.check_output(["vspace", "-f", "vspace_gaussian.in"], cwd=path)
3030

3131
# Grab the output folders
3232
folders = sorted([f.path for f in os.scandir(dir) if f.is_dir()])
@@ -93,7 +93,7 @@ def test_gaussian_nonstandard():
9393
shutil.rmtree(dir)
9494

9595
# Run vspace
96-
subprocess.check_output(["vspace", "vspace_gaussian_nonstandard.in"], cwd=path)
96+
subprocess.check_output(["vspace", "-f", "vspace_gaussian_nonstandard.in"], cwd=path)
9797

9898
# Extract values
9999
folders = sorted([f.path for f in os.scandir(dir) if f.is_dir()])

tests/Random/test_gaussian_cutoffs.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,7 @@ def test_gaussian_min_cutoff():
2424
shutil.rmtree(dir)
2525

2626
# Run vspace: Gaussian(0, 1) with min=-1.0
27-
subprocess.check_output(["vspace", "vspace_gaussian_min.in"], cwd=path)
27+
subprocess.check_output(["vspace", "-f", "vspace_gaussian_min.in"], cwd=path, stderr=subprocess.STDOUT)
2828

2929
# Extract values
3030
folders = sorted([f.path for f in os.scandir(dir) if f.is_dir()])
@@ -72,7 +72,7 @@ def test_gaussian_max_cutoff():
7272
shutil.rmtree(dir)
7373

7474
# Run vspace: Gaussian(0, 1) with max=1.0
75-
subprocess.check_output(["vspace", "vspace_gaussian_max.in"], cwd=path)
75+
subprocess.check_output(["vspace", "-f", "vspace_gaussian_max.in"], cwd=path, stderr=subprocess.STDOUT)
7676

7777
folders = sorted([f.path for f in os.scandir(dir) if f.is_dir()])
7878
values = []
@@ -118,7 +118,7 @@ def test_gaussian_both_cutoffs():
118118
shutil.rmtree(dir)
119119

120120
# Run vspace: Gaussian(0, 1) with min=-1.5, max=1.5
121-
subprocess.check_output(["vspace", "vspace_gaussian_both.in"], cwd=path)
121+
subprocess.check_output(["vspace", "-f", "vspace_gaussian_both.in"], cwd=path, stderr=subprocess.STDOUT)
122122

123123
folders = sorted([f.path for f in os.scandir(dir) if f.is_dir()])
124124
values = []

tests/Random/test_lognormal.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -25,7 +25,7 @@ def test_lognormal_basic():
2525

2626
# Run vspace with fixed seed
2727
# Using mean=0, sigma=1 for standard log-normal
28-
subprocess.check_output(["vspace", "vspace_lognormal.in"], cwd=path)
28+
subprocess.check_output(["vspace", "-f", "vspace_lognormal.in"], cwd=path)
2929

3030
# Grab the output folders
3131
folders = sorted([f.path for f in os.scandir(dir) if f.is_dir()])
@@ -91,7 +91,7 @@ def test_lognormal_nonstandard():
9191
if dir.exists():
9292
shutil.rmtree(dir)
9393

94-
subprocess.check_output(["vspace", "vspace_lognormal_nonstandard.in"], cwd=path)
94+
subprocess.check_output(["vspace", "-f", "vspace_lognormal_nonstandard.in"], cwd=path)
9595

9696
folders = sorted([f.path for f in os.scandir(dir) if f.is_dir()])
9797
values = []

tests/Random/test_loguniform.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ def test_loguniform_positive():
2727
shutil.rmtree(dir)
2828

2929
# Run vspace with fixed seed for reproducibility
30-
subprocess.check_output(["vspace", "vspace_loguniform.in"], cwd=path)
30+
subprocess.check_output(["vspace", "-f", "vspace_loguniform.in"], cwd=path)
3131

3232
# Grab the output folders
3333
folders = sorted([f.path for f in os.scandir(dir) if f.is_dir()])
@@ -102,7 +102,7 @@ def test_loguniform_negative():
102102
shutil.rmtree(dir)
103103

104104
# Run vspace with fixed seed for reproducibility
105-
subprocess.check_output(["vspace", "vspace_loguniform_neg.in"], cwd=path)
105+
subprocess.check_output(["vspace", "-f", "vspace_loguniform_neg.in"], cwd=path)
106106

107107
# Grab the output folders
108108
folders = sorted([f.path for f in os.scandir(dir) if f.is_dir()])

0 commit comments

Comments
 (0)