diff --git a/.github/workflows/coredev-60.yml b/.github/workflows/coredev-60.yml new file mode 100644 index 0000000000..ad9d9e0fbb --- /dev/null +++ b/.github/workflows/coredev-60.yml @@ -0,0 +1,7 @@ +# This is a GitHub Action for testing a PR of the current package on buildout.coredev. +# See https://github.com/plone/.github/blob/main/reusable-workflows/coredev.yml +name: Test PR on buildout.coredev 6.0 +on: pull_request +jobs: + test-coredev: + uses: plone/.github/reusable-workflows/coredev-60.yml@main diff --git a/.github/workflows/coredev.yml b/.github/workflows/coredev.yml deleted file mode 100644 index 08277dbc75..0000000000 --- a/.github/workflows/coredev.yml +++ /dev/null @@ -1,77 +0,0 @@ -# This is a gitHub Action for testing a package PR on buildout.coredev. -# For now (May 2023) it is an experiment, but I think we need it. -# Reasons: -# 1. The robot tests on Jenkins are flaky/unstable, which most likely is due -# to several robot jobs running parallel on one node. -# 2. Python 3.10 is not working with the 'Python Shining Pandas' plugin we use -# on Jenkins. We had it running with a different script for a while, but -# these changes got lost. Should be restorable, but let's try GHA. -# -# One thing to watch out for, is that robot tests are not always reported as failures. -# On the one hand there is config for that on Jenkins: -# https://github.com/plone/jenkins.plone.org/issues/297 -# On the other hand I see the same problem locally: -# https://github.com/plone/Products.CMFPlone/issues/3537 - -# TODO: put this in a reusable workflow in plone/.github: -# https://docs.github.com/en/actions/using-workflows/reusing-workflows - -name: Test PR branch on buildout.coredev. -on: pull_request -jobs: - build: - strategy: - # fail-fast: false - matrix: - python-version: ["3.7", "3.8", "3.9", "3.10"] - test-command: ["bin/test --all -m test_robot"] - include: - - python-version: "3.10" - test-command: "bin/test" - runs-on: ubuntu-latest - steps: - - name: Ubuntu setup - run: | - # needed for CMFPlone testUnicodeSplitter test: - sudo locale-gen nl_NL@euro - sudo update-locale - # Needed for Products.PortalTransforms WordTransformsTest: - sudo apt-get install -y wv - - name: Set up Python ${{ matrix.python-version }} - uses: actions/setup-python@v3 - with: - python-version: ${{ matrix.python-version }} - # cache: 'pip' would fail because we have no requirements.txt - - name: "Install Python dependencies (pip)" - uses: "py-actions/py-dependency-install@v3" - with: - path: "https://raw.githubusercontent.com/plone/buildout.coredev/6.0/requirements.txt" - - name: Cache eggs - uses: actions/cache@v3 - with: - path: eggs - key: eggs-${{ matrix.python-version }}-${{ runner.os }}- - restore-keys: | - eggs-${{ matrix.python-version }}- - - name: Run buildout - env: - package_name: ${{ github.event.repository.name }} - clone_url: ${{ github.event.pull_request.head.repo.clone_url }} - branch: ${{ github.event.pull_request.head.ref }} - run: | - echo "Using environment: package_name=$package_name clone_url=$clone_url branch=$branch" - # Create empty buildout.cfg, otherwise buildout gets confused. - touch buildout.cfg - buildout buildout:extends=https://raw.githubusercontent.com/plone/buildout.coredev/6.0/buildout.cfg buildout:git-clone-depth=1 buildout:auto-checkout+=$package_name sources:$package_name="git $clone_url branch=$branch" install instance test - - name: Run tests - env: - ROBOT_BROWSER: headlesschrome - # Especially in robot tests the deprecation warnings completely drown out the needed info. - PYTHONWARNINGS: ignore - run: ${{ matrix.test-command }} - - name: Upload parts/tests directory for debugging - uses: actions/upload-artifact@v2 - if: failure() - with: - name: plone-coredev-${{ matrix.python-version }} - path: parts/test/