diff --git a/.github/workflows/build_and_publish.yml b/.github/workflows/build_and_publish.yml index b20e54f..a0c75c1 100644 --- a/.github/workflows/build_and_publish.yml +++ b/.github/workflows/build_and_publish.yml @@ -6,7 +6,7 @@ on: tags: ['v*'] jobs: - build-and-test: + build: runs-on: ${{ matrix.os }} strategy: matrix: @@ -17,7 +17,7 @@ jobs: uses: actions/checkout@v4 with: submodules: "true" - - name: Build wheels + - name: Build wheels and test uses: pypa/cibuildwheel@v2.16.2 env: CIBW_BUILD: ${{ matrix.pyver }}-* @@ -26,7 +26,3 @@ jobs: with: name: wheels-${{ matrix.os }}-${{ matrix.pyver }}-${{ strategy.job-index }} path: wheelhouse/* - - name: Test - run: | - python -m pip install --user wheelhouse/*.whl - python -m unittest discover -v -s mplib/tests diff --git a/pyproject.toml b/pyproject.toml index fb42f34..bcc6943 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -136,6 +136,10 @@ skip = ["*-musllinux_*", "pp*"] build-frontend = "build" manylinux-x86_64-image = "kolinguo/mplib-build:latest" container-engine = { name = "docker", create-args = ["--rm"]} +# only run tests on python3.10 +test-requires = ["trimesh", "transforms3d"] +test-command = "python3.10 -m unittest discover -s {project}/tests" +test-skip = ["cp37-*", "cp38-*", "cp39-*", "cp311-*", "cp312-*"] [tool.cibuildwheel.linux] archs = ["x86_64"]