diff --git a/.github/actions/install-meltingpot/action.yml b/.github/actions/install-meltingpot/action.yml index df7aaa96..e41a35e0 100644 --- a/.github/actions/install-meltingpot/action.yml +++ b/.github/actions/install-meltingpot/action.yml @@ -26,7 +26,7 @@ runs: - name: Set up Python ${{ inputs.python-version }} id: setup-python - uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c + uses: actions/setup-python@82c7e631bb3cdc910f68e0081d67478d79c6982d with: python-version: ${{ inputs.python-version }} diff --git a/.github/workflows/sdist-test.yml b/.github/workflows/sdist-test.yml new file mode 100644 index 00000000..24485f07 --- /dev/null +++ b/.github/workflows/sdist-test.yml @@ -0,0 +1,39 @@ +# A workflow to test the sdist that will be released to PyPI + +name: sdist-test + +on: + workflow_dispatch: + +permissions: read-all + +jobs: + sdist-test: + name: Test sdist + runs-on: ubuntu-latest + timeout-minutes: 90 + + steps: + - name: Checkout Melting Pot + uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 + + - name: Build source distribution + run: python setup.py sdist + + - name: Set up Python + uses: actions/setup-python@0a5c61591373683505ea898e09a3ea4f39ef2b9c + with: + python-version: '3.11' + + - name: Install Python dependencies + run: | + pip install --upgrade pip + pip install pytest-xdist setuptools + + - name: Install source distribution + run: | + pip install dist/*.tar.gz + + - name: Test source distribution + run: | + pytest -n auto --pyargs meltingpot