Make WordPress Core


Ignore:
Timestamp:
06/06/2024 04:34:11 PM (3 months ago)
Author:
desrosj
Message:

Build/Test Tools: Make use of new reusable workflows for 5.9.

This updates the 5.9 branch to utilize the new reusable workflows in trunk introduced in [58165].

This also includes backports for a some additional improvements and bug fixes that are necessary for the local development environment to continue working long term:

  • The image and platform properties for the mysql container have been updated to always prefer amd64 containers (#60822).
  • macos-13 is now pinned for MacOS jobs instead of macos-latest (#61340).
  • Run E2E tests with and without SCRIPT_DEBUG (#58661).
  • Migrating to Docker Compose V2 (#60901).
  • Removing the version property from docker-compose.yml (#59416).
  • Improvements to how artifacts and comments for Playground testing are generated.
  • Removing SVN related commands causing failures (#61216).
  • Updating the actions/github-scripts action to the latest version.
  • Move the Memcached container into the Docker Compose config (#55700).
  • Configure Xdebug modes in the local Docker environment (#56022).

Merges [53895], [53552], [56113], [56114], [57918], [58157], [57124], [57125], [57249] to the 5.9 branch.

Props johnbillion, joemcgill, swissspidy, thelovekesh, narenin, mukesh27, JeffPaul, peterwilsoncc, zieladam, ockham, SergeyBiryukov, jorbin, Clorith, afragen.
See #55700, #61340, #60822, #61216, #60901, #61101, #59416, #59805, #61213, #58661.

Location:
branches/5.9
Files:
2 edited

Legend:

Unmodified
Added
Removed
  • branches/5.9

  • branches/5.9/.github/workflows/php-compatibility.yml

    r55516 r58358  
    3636  cancel-in-progress: true
    3737
     38# Disable permissions for all available scopes by default.
     39# Any needed permissions should be configured at the job level.
     40permissions: {}
     41
    3842jobs:
    39 
    4043  # Runs PHP compatibility testing.
    41   #
    42   # Violations are reported inline with annotations.
    43   #
    44   # Performs the following steps:
    45   # - Checks out the repository.
    46   # - Sets up PHP.
    47   # - Logs debug information.
    48   # - Configures caching for PHP compatibility scans.
    49   # - Installs Composer dependencies (use cache if possible).
    50   # - Make Composer packages available globally.
    51   # - Logs PHP_CodeSniffer debug information.
    52   # - Runs the PHP compatibility tests.
    53   # - Ensures version-controlled files are not modified or deleted.
    5444  php-compatibility:
    5545    name: Check PHP compatibility
    56     runs-on: ubuntu-latest
    57     timeout-minutes: 20
     46    uses: WordPress/wordpress-develop/.github/workflows/reusable-php-compatibility.yml@trunk
     47    permissions:
     48      contents: read
    5849    if: ${{ github.repository == 'WordPress/wordpress-develop' || github.event_name == 'pull_request' }}
    59 
    60     steps:
    61       - name: Checkout repository
    62         uses: actions/checkout@ac593985615ec2ede58e132d2e21d2b1cbd6127c # v3.3.0
    63 
    64       - name: Set up PHP
    65         uses: shivammathur/setup-php@d30ad8b1843ace22e6698ab99bbafaa747b6bd0d # v2.24.0
    66         with:
    67           php-version: '7.4'
    68           coverage: none
    69           tools: composer, cs2pr
    70 
    71       - name: Log debug information
    72         run: |
    73           php --version
    74           composer --version
    75 
    76       # This date is used to ensure that the PHP compatibility cache is cleared at least once every week.
    77       # http://man7.org/linux/man-pages/man1/date.1.html
    78       - name: "Get last Monday's date"
    79         id: get-date
    80         run: echo "date=$(/bin/date -u --date='last Mon' "+%F")" >> $GITHUB_OUTPUT
    81 
    82       - name: Cache PHP compatibility scan cache
    83         uses: actions/cache@69d9d449aced6a2ede0bc19182fadc3a0a42d2b0 # v3.2.6
    84         with:
    85           path: .cache/phpcompat.json
    86           key: ${{ runner.os }}-date-${{ steps.get-date.outputs.date }}-phpcompat-cache-${{ hashFiles('**/composer.json', 'phpcompat.xml.dist') }}
    87 
    88       - name: Install Composer dependencies
    89         uses: ramsey/composer-install@83af392bf5f031813d25e6fe4cd626cdba9a2df6 # v2.2.0
    90         with:
    91           composer-options: "--no-progress --no-ansi"
    92 
    93       - name: Make Composer packages available globally
    94         run: echo "${PWD}/vendor/bin" >> $GITHUB_PATH
    95 
    96       - name: Log PHPCS debug information
    97         run: phpcs -i
    98 
    99       - name: Run PHP compatibility tests
    100         run: phpcs --standard=phpcompat.xml.dist -q --report=checkstyle | cs2pr
    101 
    102       - name: Ensure version-controlled files are not modified or deleted
    103         run: git diff --exit-code
     50    with:
     51      php-version: '7.4'
    10452
    10553  slack-notifications:
    10654    name: Slack Notifications
    10755    uses: WordPress/wordpress-develop/.github/workflows/slack-notifications.yml@trunk
     56    permissions:
     57      actions: read
     58      contents: read
    10859    needs: [ php-compatibility ]
    10960    if: ${{ github.repository == 'WordPress/wordpress-develop' && github.event_name != 'pull_request' && always() }}
     
    11970    name: Failed workflow tasks
    12071    runs-on: ubuntu-latest
     72    permissions:
     73      actions: write
    12174    needs: [ php-compatibility, slack-notifications ]
    12275    if: |
Note: See TracChangeset for help on using the changeset viewer.