Terminate the find command. #2
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
name: Python Unit Test | |
on: | |
push: | |
branches: [main] | |
pull_request: | |
branches: [main] | |
jobs: | |
unit-tests: | |
strategy: | |
matrix: | |
python-version: ['3.8', '3.9', '3.10', '3.11', '3.12'] | |
runs-on: ubuntu-latest | |
container: | |
image: ubuntu:latest | |
steps: | |
- name: Checkout source code | |
uses: actions/checkout@v4 | |
- name: Setup Python ${{matrix.python-version}} | |
uses: actions/setup-python@v1 | |
with: | |
python-version: ${{matrix.python-version}} | |
- name: Configure apt to disable recommendations installation | |
run: | | |
echo 'APT::Install-Recommends "false";' >> /etc/apt/apt.conf | |
echo 'APT::Install-Suggests "false";' >> /etc/apt/apt.conf | |
- name: Install third-party libraries and tools | |
run: | | |
apt-get update | |
apt-get install -y cmake build-essential libboost-test-dev libfmt-dev wget unzip | |
apt-get install -y python3-pip python3-numpy | |
- name: Install Python dependencies | |
run: | | |
pip install 'torch>=2.2.0+cpu' --index-url https://download.pytorch.org/whl/cpu | |
pip install pytest | |
- name: Build and install | |
run: | | |
python setup.py build | |
find ${{github.workspace}} -name "_C.*.so" ${{github.workspace}}/torch_geopooling \; | |
- name: Run unit-tests | |
run: pytest -vv |