-
Notifications
You must be signed in to change notification settings - Fork 61
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Break out pip and doc tests, exclude doc-change from eating up precio…
…us runner cycles
- Loading branch information
1 parent
60c864e
commit 4bcb08a
Showing
7 changed files
with
92 additions
and
93 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 |
---|---|---|
|
@@ -3,6 +3,7 @@ name: Benchmarks | |
on: | ||
pull_request: | ||
branches: [ master ] | ||
paths-ignore: 'doc/**' | ||
|
||
jobs: | ||
build: | ||
|
This file was deleted.
Oops, something went wrong.
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 |
---|---|---|
|
@@ -3,6 +3,7 @@ name: Sanitize | |
on: | ||
pull_request: | ||
branches: [ master ] | ||
paths-ignore: 'doc/**' | ||
|
||
jobs: | ||
build: | ||
|
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
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,41 @@ | ||
name: Test docs | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
paths: 'doc/**' | ||
pull_request: | ||
branches: [ master ] | ||
paths: 'doc/**' | ||
|
||
jobs: | ||
testdocs: | ||
name: "Docs build test" | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
matrix: | ||
os: [ubuntu-20.04] | ||
python-version: [3.7] | ||
steps: | ||
- name: Set up cmake | ||
uses: jwlawson/[email protected] | ||
with: | ||
cmake-version: ${{ matrix.config.cmake }} | ||
- name: Set up Python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
- name: Update pip and setup venv | ||
run: python -m pip install --upgrade pip && python -m venv ~/env && . ~/env/bin/activate && echo "PATH=$PATH" >> $GITHUB_ENV | ||
- name: Clone w/ submodules | ||
uses: actions/checkout@v3 | ||
with: | ||
submodules: recursive | ||
- name: Install Python packages | ||
run: python -m pip install -r doc/requirements.txt -U | ||
- name: Build Arbor Docs | ||
run: | | ||
mkdir build | ||
cd build | ||
cmake .. -DARB_WITH_PYTHON=ON -DPython3_EXECUTABLE=`which python` -DARB_USE_BUNDLED_LIBS=ON | ||
make html |
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 |
---|---|---|
@@ -1,10 +1,12 @@ | ||
name: Test Everything | ||
name: Test Matrix | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
paths-ignore: 'doc/**' | ||
pull_request: | ||
branches: [ master ] | ||
paths-ignore: 'doc/**' | ||
|
||
jobs: | ||
testallconfigs: | ||
|
@@ -191,67 +193,3 @@ jobs: | |
# run: scripts/run_python_examples.sh | ||
- name: Test executables | ||
run: ./scripts/test_executables.sh | ||
testpip: | ||
name: "Pip build test + Python examples test" | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
matrix: | ||
os: [ubuntu-20.04] | ||
python-version: [3.7] | ||
steps: | ||
- uses: actions/setup-python@v4 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
- name: Clone w/ submodules | ||
uses: actions/checkout@v3 | ||
with: | ||
submodules: recursive | ||
- name: Update pip and setup venv | ||
run: python -m pip install --upgrade pip && python -m venv ~/env && . ~/env/bin/activate && echo PATH=$PATH >> $GITHUB_ENV | ||
- name: Debug info Python | ||
run: | | ||
which python | ||
python --version | ||
pip --version | ||
- name: Build and install Arbor using pip + build flags | ||
run: CMAKE_ARGS="-DARB_VECTORIZE=ON -DARB_ARCH=native" pip install . --user | ||
- name: Check that build flags match | ||
run: | | ||
python -c "import arbor; print(arbor.config())" | grep -q "'arch': 'native'" | ||
- name: Run Python tests | ||
run: python -m unittest discover -v -s python | ||
- name: Run Python examples | ||
run: scripts/run_python_examples.sh | ||
- name: Test executables | ||
run: scripts/test_executables.sh | ||
testdocs: | ||
name: "Docs build test" | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
matrix: | ||
os: [ubuntu-20.04] | ||
python-version: [3.7] | ||
steps: | ||
- name: Set up cmake | ||
uses: jwlawson/[email protected] | ||
with: | ||
cmake-version: ${{ matrix.config.cmake }} | ||
- name: Set up Python | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
- name: Update pip and setup venv | ||
run: python -m pip install --upgrade pip && python -m venv ~/env && . ~/env/bin/activate && echo "PATH=$PATH" >> $GITHUB_ENV | ||
- name: Clone w/ submodules | ||
uses: actions/checkout@v3 | ||
with: | ||
submodules: recursive | ||
- name: Install Python packages | ||
run: python -m pip install -r doc/requirements.txt -U | ||
- name: Build Arbor Docs | ||
run: | | ||
mkdir build | ||
cd build | ||
cmake .. -DARB_WITH_PYTHON=ON -DPython3_EXECUTABLE=`which python` -DARB_USE_BUNDLED_LIBS=ON | ||
make html | ||
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,44 @@ | ||
name: Test pip | ||
|
||
on: | ||
push: | ||
branches: [ master ] | ||
paths-ignore: 'doc/**' | ||
pull_request: | ||
branches: [ master ] | ||
paths-ignore: 'doc/**' | ||
|
||
jobs: | ||
testpip: | ||
name: "Pip build test + Python examples test" | ||
runs-on: ${{ matrix.os }} | ||
strategy: | ||
matrix: | ||
os: [ubuntu-20.04] | ||
python-version: [3.7] | ||
steps: | ||
- uses: actions/setup-python@v4 | ||
with: | ||
python-version: ${{ matrix.python-version }} | ||
- name: Clone w/ submodules | ||
uses: actions/checkout@v3 | ||
with: | ||
submodules: recursive | ||
- name: Update pip and setup venv | ||
run: python -m pip install --upgrade pip && python -m venv ~/env && . ~/env/bin/activate && echo PATH=$PATH >> $GITHUB_ENV | ||
- name: Debug info Python | ||
run: | | ||
which python | ||
python --version | ||
pip --version | ||
- name: Build and install Arbor using pip + build flags | ||
run: CMAKE_ARGS="-DARB_VECTORIZE=ON -DARB_ARCH=native" pip install . --user | ||
- name: Check that build flags match | ||
run: | | ||
python -c "import arbor; print(arbor.config())" | grep -q "'arch': 'native'" | ||
- name: Run Python tests | ||
run: python -m unittest discover -v -s python | ||
- name: Run Python examples | ||
run: scripts/run_python_examples.sh | ||
- name: Test executables | ||
run: scripts/test_executables.sh |