diff --git a/.github/workflows/build-and-test.yaml b/.github/workflows/build-and-test.yaml index bea6486..fb1747c 100644 --- a/.github/workflows/build-and-test.yaml +++ b/.github/workflows/build-and-test.yaml @@ -8,7 +8,7 @@ on: workflow_dispatch: jobs: - build_ubuntu: + build_and_test_ubuntu: runs-on: ubuntu-20.04 steps: - name: Checkout code @@ -19,7 +19,6 @@ jobs: python-version: "3.8" - name: Install dependencies run: | - sudo apt-get update pip install --upgrade setuptools wheel auditwheel patchelf - name: Build the wheel run: python setup.py bdist_wheel @@ -29,6 +28,12 @@ jobs: run: | auditwheel show dist/*.whl auditwheel repair dist/*.whl --plat manylinux_2_31_x86_64 -w wheelhouse/ + - name: Install the wheel + run: | + pip install wheelhouse/traceon-*.whl + pip show traceon + - name: Run tests + run: python -m unittest tests/*.py - name: Upload wheel artifact uses: actions/upload-artifact@v3 with: @@ -39,8 +44,7 @@ jobs: with: name: source-distribution path: dist/*.tar.gz - - + build_windows: runs-on: windows-latest steps: @@ -61,33 +65,7 @@ jobs: with: name: windows-wheel path: dist/*.whl - - test_ubuntu: - needs: build_ubuntu - runs-on: ubuntu-20.04 - steps: - - name: Set up Python - uses: actions/setup-python@v4 - with: - python-version: "3.8" - - name: Install dependencies - run: | - sudo apt-get update - sudo apt-get install -y gmsh - - name: Checkout code - uses: actions/checkout@v3 - - name: Download wheel artifact - uses: actions/download-artifact@v3 - with: - name: ubuntu-wheel - path: ./ - - name: Install the wheel - run: | - pip install traceon-*.whl - pip show traceon - - name: Run tests - run: python -m unittest tests/*.py - + test_windows: needs: build_windows runs-on: windows-latest