Skip to content

[BUG FIX] Minor bug fixes and maintenance. #864

[BUG FIX] Minor bug fixes and maintenance.

[BUG FIX] Minor bug fixes and maintenance. #864

Workflow file for this run

name: CI
on:
push:
branches:
- main
pull_request:
branches:
- main
jobs:
test-linux-gpu:
runs-on: self-hosted
strategy:
fail-fast: false
matrix:
python-version: ["3.12"]
steps:
- name: Checkout code
uses: actions/checkout@v4
with:
fetch-depth: 1
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.x'
- name: Install Dependencies
run: |
pip install black
- name: Black Format Check
run: black --line-length 120 --check .
- name: Run Tests
run: |
container_id=$(uuidgen)
artifacts_id="${container_id}_$(date +%Y%m%d_%H%M%S)"
echo "artifacts_id=${artifacts_id}" >> $GITHUB_ENV
docker run --gpus all --name $container_id -v ${{ github.workspace }}:/workspace:ro cuda11:latest \
bash -c "
source \"\$HOME/.bash_profile\" && \
cp -r /workspace /app && cd /app && \
bash ./.github/workflows/setup_env.sh && \
curl -sS 'https://api.github.com/repos/ompl/ompl/releases/tags/prerelease' \
| jq -r '.assets[].browser_download_url' \
| while IFS= read -r URL; do wget -q -c \"\$URL\"; done && \
pyenv shell "${{ matrix.python-version }}" && \
python -m pip install --no-index --find-links . ompl && \
pip install -e ".[dev]" && \
pytest -v tests && \
pytest -v -m 'benchmarks' tests"
mkdir -p ./artifacts
docker cp "$container_id:/app/speed_test.txt" "./artifacts/speed_test_${artifacts_id}.txt"
docker rm "$container_id"
- name: Display Speed Test
run: |
cat "./artifacts/speed_test_${artifacts_id}.txt"
- name: Upload Test Results as Artifact
uses: actions/upload-artifact@v4
with:
name: speed-test-results
path: "artifacts/speed_test_${{ env.artifacts_id }}.txt"