Skip to content

Commit d56aea7

Browse files
committed
combine and clean up ci
1 parent 1d6a55c commit d56aea7

File tree

3 files changed

+45
-53
lines changed

3 files changed

+45
-53
lines changed

.github/workflows/ci.yaml

Lines changed: 45 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,45 @@
1+
---
2+
# based on https://github.com/actions/starter-workflows/blob/main/ci/cmake-single-platform.yml
3+
name: 'Spark-DSG Build and Test'
4+
on: [pull_request]
5+
jobs:
6+
lint:
7+
runs-on: ubuntu-latest
8+
steps:
9+
- uses: actions/checkout@v4
10+
- name: Dependencies
11+
run: sudo apt-get update && sudo apt install pipx
12+
- name: Lint
13+
run: pipx install pre-commit && cd ${{github.workspace}} && pre-commit run --all-files
14+
cmake:
15+
runs-on: ubuntu-latest
16+
steps:
17+
- uses: actions/checkout@v4
18+
- name: Dependencies
19+
run: sudo apt-get update && sudo apt install libgtest-dev libeigen3-dev nlohmann-json3-dev libzmq3-dev
20+
- name: Configure
21+
run: cmake -B ${{github.workspace}}/build -DBUILD_TESTING=ON -DCMAKE_BUILD_TYPE=Release -DSPARK_DSG_BUILD_TESTS=ON -DSPARK_DSG_BUILD_EXAMPLES=ON
22+
- name: Build
23+
run: cmake --build ${{github.workspace}}/build --config Release
24+
- name: Test
25+
working-directory: ${{github.workspace}}/build
26+
run: ctest -C Release
27+
python:
28+
runs-on: ubuntu-latest
29+
strategy: {matrix: {python-version: ['3.8', '3.10', '3.12']}}
30+
steps:
31+
- uses: actions/checkout@v4
32+
- name: Setup Python ${{ matrix.python-version }}
33+
uses: actions/setup-python@v5
34+
with: {python-version: ${{ matrix.python-version }}}
35+
- name: Dependencies
36+
run: |
37+
python -m pip install --upgrade pip
38+
sudo apt-get update && sudo apt install libgtest-dev libeigen3-dev nlohmann-json3-dev libzmq3-dev python3-dev
39+
- name: Install
40+
run: python -m pip install ${{github.workspace}}
41+
- name: Test
42+
run: |-
43+
pip install torch --index-url https://download.pytorch.org/whl/cpu
44+
pip install pytest networkx torch_geometric
45+
pytest ${{github.workspace}}/python/tests

.github/workflows/cmake.yaml

Lines changed: 0 additions & 26 deletions
This file was deleted.

.github/workflows/python.yaml

Lines changed: 0 additions & 27 deletions
This file was deleted.

0 commit comments

Comments
 (0)