-
Notifications
You must be signed in to change notification settings - Fork 64
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
* testing gh * test install * basic * almost there * fake * test name * coveralls * note * note * OSs and PYs * OSs and PYs * OSs and PYs * no mac for now * just mac, testing * just mac, testing * just mac, testing * just mac, testing * just mac, testing * just mac, testing * just mac, testing * just mac, testing * just mac, testing * just mac, testing * just mac, testing * just mac, testing * just mac, testing * mac and ubuntu * mac and ubuntu * mac and ubuntu * mac and ubuntu * mac and ubuntu * mac and ubuntu * mac and ubuntu * mac and ubuntu * mac and ubuntu * mac and ubuntu * class... * class... * class... * class... * class... * class... * class... * swig... * cleanup * oops * simpler class * c tests * c tests * MJ comments * master
- Loading branch information
Showing
7 changed files
with
136 additions
and
202 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 |
---|---|---|
@@ -0,0 +1,136 @@ | ||
name: continuous-integration | ||
on: | ||
push: | ||
branches: | ||
- main | ||
- master | ||
- releases/* | ||
pull_request: | ||
branches: | ||
- main | ||
- master | ||
- releases/* | ||
jobs: | ||
build: | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
matrix: | ||
os: [ ubuntu-latest ] | ||
py: [ 3.6, 3.7, 3.8, 3.9 ] | ||
CC: [ gcc ] | ||
|
||
# Check macos too | ||
include: | ||
- os: macos-latest | ||
py: 3.7 | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
|
||
- name: Set up Python ${{ matrix.py }} | ||
uses: actions/setup-python@v2 | ||
with: | ||
python-version: ${{ matrix.py }} | ||
|
||
- name: Install GFortran macOS | ||
# brew returns a failure exit code if | ||
# the thing is already installed and | ||
# current. Hence the `|| true` statement | ||
if: matrix.os == 'macos-latest' | ||
run: | | ||
brew cask install gfortran || true | ||
- name: Install GSL, FFTW, SWIG (macos) | ||
if: matrix.os == 'macos-latest' | ||
run: | | ||
brew install fftw || true | ||
brew install gsl || true | ||
brew install swig || true | ||
- name: Install GSL, FFTW (linux) | ||
if: matrix.os == 'ubuntu-latest' | ||
run: | | ||
sudo -H apt-get install libgsl-dev libfftw3-dev | ||
- name: Install python dependencies | ||
run: | | ||
python -m pip install -U pip | ||
pip install -U numpy | ||
pip install -U scipy | ||
pip install -U pytest | ||
pip install -U pytest-cov | ||
pip install -U fast-pt | ||
pip install -U camb | ||
pip install -U isitgr | ||
pip install -U cython | ||
pip install -U flake8 | ||
- name: Install CLASS (linux) | ||
if: matrix.os == 'ubuntu-latest' | ||
run: | | ||
git clone -b v2.7.2 --single-branch --depth 1 "https://github.com/lesgourg/class_public.git" | ||
cd class_public | ||
make | ||
- name: Install CLASS (macos) | ||
if: matrix.os == 'macos-latest' | ||
run: | | ||
git clone -b v2.7.2 --single-branch --depth 1 "https://github.com/lesgourg/class_public.git" | ||
cd class_public | ||
make CC=gcc-9 | ||
- name: Flake | ||
run: | | ||
flake8 pyccl | ||
flake8 --exclude=data benchmarks | ||
- name: Build CCL | ||
run: | | ||
python setup.py build | ||
python setup.py develop | ||
- name: C unit tests | ||
run: | | ||
cd build | ||
make -j4 | ||
CLASS_PARAM_DIR=./extern/share/class/ OMP_NUM_THREADS=2 ./check_ccl | ||
- name: Python unit tests | ||
run: OMP_NUM_THREADS=2 pytest -vv pyccl --cov=pyccl | ||
|
||
- name: Benchmarks | ||
run: OMP_NUM_THREADS=2 pytest -vv benchmarks --cov=pyccl --cov-append | ||
|
||
- name: Coveralls | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
run: | | ||
pip install -U coveralls | ||
coveralls | ||
- name: Cache pip, brew | ||
uses: actions/cache@v2 | ||
with: | ||
path: | | ||
~/.cache/pip | ||
$HOME/Library/Caches/Homebrew | ||
/usr/local/Cellar | ||
key: ${{ runner.os }}-${{ matrix.py }}-cache | ||
restore-keys: | | ||
${{ runner.os }}-${{ matrix.py }}-cache | ||
${{ runner.os }}- | ||
build-doc-only-ubuntu: | ||
runs-on: ubuntu-latest | ||
|
||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Install prereq using apt | ||
run: | | ||
sudo apt install texlive texlive-bibtex-extra texlive-science texlive-publishers latexmk python3-sphinx python3-sphinx-rtd-theme python3-nbconvert python3-jupyter-client jupyter-client jupyter-nbconvert sphinx-common pandoc python3-setuptools -y | ||
sudo pip3 install mkauthlist | ||
- name: Building docs | ||
run: | | ||
cd doc/0000-ccl_note | ||
make |
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.
This file was deleted.
Oops, something went wrong.