Release version 1.6b1 #686
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Workflow that installs SNOwGLoBES and runs an integration test | |
name: Integration Tests | |
# Controls when the action will run. Triggers the workflow on push or pull request | |
# events but only for the main branch | |
on: | |
push: | |
branches: | |
- main | |
- release_* | |
pull_request: | |
branches: | |
- main | |
- release_* | |
types: [opened, synchronize, reopened, ready_for_review] | |
jobs: | |
run: | |
# Only execute integration tests if PR is *not* a draft | |
if: github.event.pull_request.draft == false | |
strategy: | |
matrix: | |
# Test all supported Python versions under Ubuntu | |
os: [ubuntu-latest] | |
python-version: ['3.9', '3.10', '3.11', '3.12', '3.13'] | |
# Additionally, test one Python version under MacOS and Windows, to detect OS-specific issues | |
include: | |
- os: macos-latest | |
python-version: '3.12' | |
- os: windows-latest | |
python-version: '3.12' | |
runs-on: ${{ matrix.os }} | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set up Python ${{ matrix.python-version }} | |
uses: actions/setup-python@v5 | |
with: | |
python-version: ${{ matrix.python-version }} | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
- name: Install SNEWPY | |
run: | | |
pip install ".[dev]" | |
- name: Run Integration Tests | |
run: | | |
python -m unittest python/snewpy/test/simplerate_integrationtest.py | |
pytest -m 'snowglobes' | |
- name: Run Jupyter notebooks | |
if: ${{ ! startsWith(matrix.os, 'windows') }} | |
run: | | |
pip install nbclient ipykernel | |
jupyter kernelspec list | |
cd doc/nb/ | |
jupyter execute ccsn/*.ipynb | |
jupyter execute presn/*.ipynb | |
jupyter execute AnalyticFluence.ipynb FlavorTransformation.ipynb | |
# Download necessary progenitor file, before executing the notebook | |
python -c 'from snewpy.models.ccsn import Zha_2021; from astropy import units as u; _ = Zha_2021(progenitor_mass=17*u.solMass)' | |
jupyter execute SNOwGLoBES_usage.ipynb | |
- name: Run Jupyter notebooks on Windows | |
if: ${{ startsWith(matrix.os, 'windows') }} | |
run: | | |
pip install nbclient ipykernel | |
jupyter kernelspec list | |
cd doc\nb\ | |
jupyter execute (get-item ccsn\*.ipynb) | |
jupyter execute (get-item presn\*.ipynb) | |
jupyter execute AnalyticFluence.ipynb FlavorTransformation.ipynb | |
# Download necessary progenitor file, before executing the notebook | |
python -c 'from snewpy.models.ccsn import Zha_2021; from astropy import units as u; _ = Zha_2021(progenitor_mass=17*u.solMass)' | |
jupyter execute SNOwGLoBES_usage.ipynb |