51 lines
1.2 KiB
YAML
51 lines
1.2 KiB
YAML
name: PR code review
|
|
|
|
on:
|
|
workflow_dispatch:
|
|
pull_request:
|
|
branches:
|
|
- pybind11
|
|
push:
|
|
branches:
|
|
- pybind11
|
|
|
|
concurrency:
|
|
group: ${{ github.workflow }}-${{ github.ref }}
|
|
cancel-in-progress: true
|
|
|
|
jobs:
|
|
build:
|
|
strategy:
|
|
fail-fast: false
|
|
matrix:
|
|
platform: [windows-latest, macos-latest, ubuntu-latest]
|
|
python-version: ["3.9", "3.12"]
|
|
|
|
runs-on: ${{ matrix.platform }}
|
|
|
|
steps:
|
|
- uses: actions/checkout@v4
|
|
with:
|
|
submodules: true
|
|
|
|
- uses: actions/setup-python@v5
|
|
with:
|
|
python-version: ${{ matrix.python-version }}
|
|
|
|
- name: Upgrade pip
|
|
run: python -m pip install --upgrade pip
|
|
|
|
- name: Installing dependencies
|
|
uses: py-actions/py-dependency-install@v4
|
|
with:
|
|
path: "requirements.txt"
|
|
|
|
- name: Add requirements
|
|
run: python -m pip install --upgrade setuptools wheel build packaging
|
|
|
|
- name: Build and install
|
|
run: pip install --verbose .
|
|
|
|
- name: Smoke test
|
|
run: python -c "import os, tempfile; os.chdir(tempfile.gettempdir()); import easygraph as eg; G = eg.Graph(); G.add_edge(1, 2); assert G.number_of_nodes() == 2; assert G.number_of_edges() == 1"
|