-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #69 from deepanshs/djs/test_mac
Add test coverage for mac os
- Loading branch information
Showing
1 changed file
with
39 additions
and
8 deletions.
There are no files selected for viewing
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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -33,35 +33,66 @@ jobs: | |
flake8 . --count --select=B,C,E,F,W,T,N8 --ignore=E203 --max-line-length=88 --show-source --statistics --exclude="examples/* docs/* build/* utils.py" | ||
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide | ||
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=88 --statistics --exclude="examples/* docs/* build/* utils.py" | ||
testing_unix: | ||
needs: [code_lint] | ||
runs-on: ubuntu-latest | ||
strategy: | ||
matrix: | ||
python-version: [3.8, 3.9, "3.10", "3.11"] | ||
python-version: [3.9, "3.10", "3.11"] | ||
|
||
steps: | ||
- name: Checkout | ||
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 | ||
pip install flake8 pytest | ||
pip install -r requirements.txt | ||
pip install setuptools | ||
pip install -r requirements-dev.txt | ||
- name: Lint with flake8 | ||
- name: Build and install package from source | ||
run: python setup.py develop | ||
|
||
- name: Test with pytest | ||
run: pytest --cov=./ --cov-report=xml | ||
|
||
- name: Upload coverage | ||
uses: codecov/[email protected] | ||
|
||
testing_mac_intel: | ||
needs: [code_lint] | ||
runs-on: "macos-13" | ||
strategy: | ||
matrix: | ||
python-version: [3.9, "3.10", "3.11"] | ||
|
||
steps: | ||
- name: Checkout | ||
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: | | ||
# stop the build if there are Python syntax errors or undefined names | ||
flake8 . --count --select=C,E,F,W,N8 --show-source --statistics --exclude="examples/* *.npy docs/* *.pyx *.pxd mrinversion/kernel/__init__.py mrinversion/utils.py" | ||
# exit-zero treats all errors as warnings. The GitHub editor is 127 chars wide | ||
flake8 . --count --exit-zero --max-complexity=10 --max-line-length=88 --statistics --exclude="examples/* *.npy docs/* *.pyx *.pxd mrinversion/kernel/__init__.py mrinversion/utils.py" | ||
brew install gfortran | ||
python -m pip install --upgrade pip | ||
pip install setuptools | ||
pip install -r requirements-dev.txt | ||
- name: Build and install package from source | ||
run: python setup.py develop | ||
|
||
- name: Test with pytest | ||
run: pytest --cov=./ --cov-report=xml | ||
|
||
- name: Upload coverage | ||
uses: codecov/[email protected] |