Skip to content

MAINT: numpy 2 transition #278

MAINT: numpy 2 transition

MAINT: numpy 2 transition #278

Workflow file for this run

name: Test
on:
- push
- pull_request
jobs:
test_linux:
runs-on: ubuntu-latest
strategy:
max-parallel: 3
matrix:
python-version: ["3.10", "3.11"]
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Build wheel
run: |
python -m pip install build
python -m build .
- name: Test with pytest
run: |
pushd dist
python -m pip install pytest numpy scipy pandas refnx>=0.1.27
python -m pip install --only-binary=refellips --no-index --find-links=. refellips
pytest --pyargs refellips
popd
- uses: actions/upload-artifact@v1
with:
name: refellips-wheel
path: dist/
lint:
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.11"]
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Lint with black
run: |
python -m pip install black[jupyter] flake8
black --check -l80 refellips
black --check -l80 demos
black --check -l80 docs
flake8 --ignore=F401,E501,W504,W503,E203,E231,E402 --count --statistics refellips
build_doc:
runs-on: ubuntu-latest
strategy:
max-parallel: 1
matrix:
python-version: ["3.10"]
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: setup apt dependencies
run: |
sudo apt-get update
sudo apt-get install pandoc
- name: Build documentation
run: |
python -m pip install --upgrade pip
python -m pip install .
python -m pip install wheel
cd docs
python -m pip install -r requirements.txt
make html
run_demos:
runs-on: ubuntu-latest
strategy:
max-parallel: 1
matrix:
python-version: ["3.11"]
steps:
- uses: actions/checkout@v2
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}
- name: Build wheel
run: |
python -m pip install build
python -m build .
- name: Install dependencies
run: |
pushd dist
python -m pip install pytest jupyter nbmake numpy matplotlib scipy pandas refnx>=0.1.27
python -m pip install --only-binary=refellips --no-index --find-links=. refellips
popd
- name: Run demos
run: |
pytest --nbmake ./demos