<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN"
"http://www.w3.org/TR/xhtml11/DTD/xhtml11.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head><meta http-equiv="content-type" content="text/html; charset=utf-8" />
<title>[53616] branches/4.5/.github/workflows: Build/Test Tools: Use the Slack notifications workflow as a reusable one.</title>
</head>
<body>
<style type="text/css"><!--
#msg dl.meta { border: 1px #006 solid; background: #369; padding: 6px; color: #fff; }
#msg dl.meta dt { float: left; width: 6em; font-weight: bold; }
#msg dt:after { content:':';}
#msg dl, #msg dt, #msg ul, #msg li, #header, #footer, #logmsg { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; }
#msg dl a { font-weight: bold}
#msg dl a:link { color:#fc3; }
#msg dl a:active { color:#ff0; }
#msg dl a:visited { color:#cc6; }
h3 { font-family: verdana,arial,helvetica,sans-serif; font-size: 10pt; font-weight: bold; }
#msg pre { white-space: pre-line; overflow: auto; background: #ffc; border: 1px #fa0 solid; padding: 6px; }
#logmsg { background: #ffc; border: 1px #fa0 solid; padding: 1em 1em 0 1em; }
#logmsg p, #logmsg pre, #logmsg blockquote { margin: 0 0 1em 0; }
#logmsg p, #logmsg li, #logmsg dt, #logmsg dd { line-height: 14pt; }
#logmsg h1, #logmsg h2, #logmsg h3, #logmsg h4, #logmsg h5, #logmsg h6 { margin: .5em 0; }
#logmsg h1:first-child, #logmsg h2:first-child, #logmsg h3:first-child, #logmsg h4:first-child, #logmsg h5:first-child, #logmsg h6:first-child { margin-top: 0; }
#logmsg ul, #logmsg ol { padding: 0; list-style-position: inside; margin: 0 0 0 1em; }
#logmsg ul { text-indent: -1em; padding-left: 1em; }#logmsg ol { text-indent: -1.5em; padding-left: 1.5em; }
#logmsg > ul, #logmsg > ol { margin: 0 0 1em 0; }
#logmsg pre { background: #eee; padding: 1em; }
#logmsg blockquote { border: 1px solid #fa0; border-left-width: 10px; padding: 1em 1em 0 1em; background: white;}
#logmsg dl { margin: 0; }
#logmsg dt { font-weight: bold; }
#logmsg dd { margin: 0; padding: 0 0 0.5em 0; }
#logmsg dd:before { content:'\00bb';}
#logmsg table { border-spacing: 0px; border-collapse: collapse; border-top: 4px solid #fa0; border-bottom: 1px solid #fa0; background: #fff; }
#logmsg table th { text-align: left; font-weight: normal; padding: 0.2em 0.5em; border-top: 1px dotted #fa0; }
#logmsg table td { text-align: right; border-top: 1px dotted #fa0; padding: 0.2em 0.5em; }
#logmsg table thead th { text-align: center; border-bottom: 1px solid #fa0; }
#logmsg table th.Corner { text-align: left; }
#logmsg hr { border: none 0; border-top: 2px dashed #fa0; height: 1px; }
#header, #footer { color: #fff; background: #636; border: 1px #300 solid; padding: 6px; }
#patch { width: 100%; }
#patch h4 {font-family: verdana,arial,helvetica,sans-serif;font-size:10pt;padding:8px;background:#369;color:#fff;margin:0;}
#patch .propset h4, #patch .binary h4 {margin:0;}
#patch pre {padding:0;line-height:1.2em;margin:0;}
#patch .diff {width:100%;background:#eee;padding: 0 0 10px 0;overflow:auto;}
#patch .propset .diff, #patch .binary .diff {padding:10px 0;}
#patch span {display:block;padding:0 10px;}
#patch .modfile, #patch .addfile, #patch .delfile, #patch .propset, #patch .binary, #patch .copfile {border:1px solid #ccc;margin:10px 0;}
#patch ins {background:#dfd;text-decoration:none;display:block;padding:0 10px;}
#patch del {background:#fdd;text-decoration:none;display:block;padding:0 10px;}
#patch .lines, .info {color:#888;background:#fff;}
--></style>
<div id="msg">
<dl class="meta" style="font-size: 105%">
<dt style="float: left; width: 6em; font-weight: bold">Revision</dt> <dd><a style="font-weight: bold" href="https://core.trac.wordpress.org/changeset/53616">53616</a><script type="application/ld+json">{"@context":"http://schema.org","@type":"EmailMessage","description":"Review this Commit","action":{"@type":"ViewAction","url":"https://core.trac.wordpress.org/changeset/53616","name":"Review Commit"}}</script></dd>
<dt style="float: left; width: 6em; font-weight: bold">Author</dt> <dd>desrosj</dd>
<dt style="float: left; width: 6em; font-weight: bold">Date</dt> <dd>2022-06-30 17:19:15 +0000 (Thu, 30 Jun 2022)</dd>
</dl>
<pre style='padding-left: 1em; margin: 2em 0; border-left: 2px solid #ccc; line-height: 1.25; font-size: 105%; font-family: sans-serif'>Build/Test Tools: Use the Slack notifications workflow as a reusable one.
This backports several changesets that are required to remove the reliance on the `workflow_run` event for posting Slack notifications.
The Slack notification workflow will now be called as a reusable one, which has several benefits (see <a href="https://core.trac.wordpress.org/changeset/53591">[53591]</a>).
Several other minor GitHub Actions related updates are also being backported in this commit to maintain tooling consistency across branches that still receive security updates as a courtesy when necessary.
Workflows that are not relevant to this branch that were mistakenly backported are also being deleted.
Merges <a href="https://core.trac.wordpress.org/changeset/50473">[50473]</a>, <a href="https://core.trac.wordpress.org/changeset/50704">[50704]</a>, <a href="https://core.trac.wordpress.org/changeset/50930">[50930]</a>, <a href="https://core.trac.wordpress.org/changeset/51341">[51341]</a>, <a href="https://core.trac.wordpress.org/changeset/51355">[51355]</a>, <a href="https://core.trac.wordpress.org/changeset/51498">[51498]</a>, <a href="https://core.trac.wordpress.org/changeset/51511">[51511]</a>, <a href="https://core.trac.wordpress.org/changeset/51535">[51535]</a>, <a href="https://core.trac.wordpress.org/changeset/51924">[51924]</a>, <a href="https://core.trac.wordpress.org/changeset/51925">[51925]</a>, <a href="https://core.trac.wordpress.org/changeset/51937">[51937]</a>, <a href="https://core.trac.wordpress.org/changeset/52002">[52002]</a>, <a href="https://core.trac.wordpress.org/changeset/52130">[52130]</a>, <a href="https://core.trac.wordpress.org/changeset/52183">[52183]</a
>, <a href="https://core.trac.wordpress.org/changeset/52233">[52233]</a>, <a href="https://core.trac.wordpress.org/changeset/53112">[53112]</a>, <a href="https://core.trac.wordpress.org/changeset/53581">[53581]</a>, <a href="https://core.trac.wordpress.org/changeset/53582">[53582]</a>, <a href="https://core.trac.wordpress.org/changeset/53592">[53592]</a> to the 4.5 branch.
See <a href="https://core.trac.wordpress.org/ticket/56095">#56095</a>.</pre>
<h3>Modified Paths</h3>
<ul>
<li><a href="#branches45githubworkflowscodingstandardsyml">branches/4.5/.github/workflows/coding-standards.yml</a></li>
<li><a href="#branches45githubworkflowsjavascripttestsyml">branches/4.5/.github/workflows/javascript-tests.yml</a></li>
<li><a href="#branches45githubworkflowsphpunittestsyml">branches/4.5/.github/workflows/phpunit-tests.yml</a></li>
<li><a href="#branches45githubworkflowstestnpmyml">branches/4.5/.github/workflows/test-npm.yml</a></li>
<li><a href="#branches45githubworkflowswelcomenewcontributorsyml">branches/4.5/.github/workflows/welcome-new-contributors.yml</a></li>
</ul>
<h3>Removed Paths</h3>
<ul>
<li><a href="#branches45githubworkflowsendtoendtestsyml">branches/4.5/.github/workflows/end-to-end-tests.yml</a></li>
<li><a href="#branches45githubworkflowsphpcompatibilityyml">branches/4.5/.github/workflows/php-compatibility.yml</a></li>
</ul>
<h3>Property Changed</h3>
<ul>
<li><a href="#branches45">branches/4.5/</a></li>
</ul>
</div>
<div id="patch">
<h3>Diff</h3>
<span class="cx" style="display: block; padding: 0 10px">Index: branches/4.5
</span><span class="cx" style="display: block; padding: 0 10px">===================================================================
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">--- branches/4.5 2022-06-30 17:18:38 UTC (rev 53615)
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+++ branches/4.5 2022-06-30 17:19:15 UTC (rev 53616)
</ins><a id="branches45"></a>
<div class="propset"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Property changes: branches/4.5</h4>
<pre class="diff"><span>
</span></pre></div>
<a id="svnmergeinfo"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: svn:mergeinfo</h4></div>
<span class="cx" style="display: block; padding: 0 10px"> /branches/4.9:42434,49653
</span><span class="cx" style="display: block; padding: 0 10px"> /branches/5.0:43684-43686,43836,43853,43988,43994,44014,44017,44047
</span><span class="cx" style="display: block; padding: 0 10px"> /branches/5.5:49373-49379,49381
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-/trunk:37185,37192,37212,37228,37247,37249,37273,37282,37285,37288,37301,37352,37417,37433,37435,37448,37452,37472,37525-37527,37559,37612,37651,37678,37697,37708,37710,37720,37724,37729-37730,37748,37755,38111,38524,38688,38757,39110,39113-39119,39360-39361,39478,39645,39659,39759-39760,39772,39795,39807-39808,39831,39850,39956,40148,40160,40169,40183,40195,40241,40255,40257-40259,40269,40271,40400,40538,40604,40677,40692,40704,40716,40723,40736,40851-40852,41072,41393,41395,41397-41398,41448,41457,41470,41483,41496,41522,41662,41712,41870,41920,42056,42119-42120,42258-42261,42424,42433,42460-42461,42463,42887,42892-42894,43320,43323,43511-43512,43977,44021,44048,44176,44219,44233,44728,44833,44842,44864,44993,45321,45445,45745,45762,45765,45783-45784,45800,45819,45885,45936,45971,45990,45997,46320,46404,46408-46409,46474-46478,46483,46485,46682,46895,46996,46999,47225,47341,47404,47634
-47635,47637-47638,47867-47869,47872-47873,47912,47947-47951,48121,48241,48705,49162,49168-49169,49175,49204,49227-49228,49244,49267,49335,49358,49360,49362,49369,49371,49380,49382-49388,49548,49636,49781-49784,49786,49836,49876,49933,49937-49939,50017,50126,50176,50185,50268,50285,50298,50379,50387,50416,50432,50435-50436,50444,50446,50473-50474,50476,50479,50485-50487,50545,50579,50590,50799,52454-52457,52844
</del><span class="cx" style="display: block; padding: 0 10px">\ No newline at end of property
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+/trunk:37185,37192,37212,37228,37247,37249,37273,37282,37285,37288,37301,37352,37417,37433,37435,37448,37452,37472,37525-37527,37559,37612,37651,37678,37697,37708,37710,37720,37724,37729-37730,37748,37755,38111,38524,38688,38757,39110,39113-39119,39360-39361,39478,39645,39659,39759-39760,39772,39795,39807-39808,39831,39850,39956,40148,40160,40169,40183,40195,40241,40255,40257-40259,40269,40271,40400,40538,40604,40677,40692,40704,40716,40723,40736,40851-40852,41072,41393,41395,41397-41398,41448,41457,41470,41483,41496,41522,41662,41712,41870,41920,42056,42119-42120,42258-42261,42424,42433,42460-42461,42463,42887,42892-42894,43320,43323,43511-43512,43977,44021,44048,44176,44219,44233,44728,44833,44842,44864,44993,45321,45445,45745,45762,45765,45783-45784,45800,45819,45885,45936,45971,45990,45997,46320,46404,46408-46409,46474-46478,46483,46485,46682,46895,46996,46999,47225,47341,47404,47634
-47635,47637-47638,47867-47869,47872-47873,47912,47947-47951,48121,48241,48705,49162,49168-49169,49175,49204,49227-49228,49244,49267,49335,49358,49360,49362,49369,49371,49380,49382-49388,49548,49636,49781-49784,49786,49836,49876,49933,49937-49939,50017,50126,50176,50185,50268,50285,50298,50379,50387,50416,50432,50435-50436,50444,50446,50473-50474,50476,50479,50485-50487,50545,50579,50590,50704,50799,50930,51341,51355,51498,51511,51535,51921,51924-51925,51937,52002,52130,52183,52233,52454-52457,52844,53112,53581-53582,53592
</ins><span class="cx" style="display: block; padding: 0 10px">\ No newline at end of property
</span><a id="branches45githubworkflowscodingstandardsyml"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: branches/4.5/.github/workflows/coding-standards.yml</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- branches/4.5/.github/workflows/coding-standards.yml 2022-06-30 17:18:38 UTC (rev 53615)
+++ branches/4.5/.github/workflows/coding-standards.yml 2022-06-30 17:19:15 UTC (rev 53616)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -5,7 +5,6 @@
</span><span class="cx" style="display: block; padding: 0 10px"> # PHPCS checking was introduced in WordPress 5.1.
</span><span class="cx" style="display: block; padding: 0 10px"> push:
</span><span class="cx" style="display: block; padding: 0 10px"> branches:
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- - master
</del><span class="cx" style="display: block; padding: 0 10px"> - trunk
</span><span class="cx" style="display: block; padding: 0 10px"> - '3.[89]'
</span><span class="cx" style="display: block; padding: 0 10px"> - '[4-9].[0-9]'
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -14,7 +13,6 @@
</span><span class="cx" style="display: block; padding: 0 10px"> - '[4-9].[0-9]*'
</span><span class="cx" style="display: block; padding: 0 10px"> pull_request:
</span><span class="cx" style="display: block; padding: 0 10px"> branches:
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- - master
</del><span class="cx" style="display: block; padding: 0 10px"> - trunk
</span><span class="cx" style="display: block; padding: 0 10px"> - '3.[89]'
</span><span class="cx" style="display: block; padding: 0 10px"> - '[4-9].[0-9]'
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -34,6 +32,13 @@
</span><span class="cx" style="display: block; padding: 0 10px"> - '.github/workflows/*.yml'
</span><span class="cx" style="display: block; padding: 0 10px"> workflow_dispatch:
</span><span class="cx" style="display: block; padding: 0 10px">
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+# Cancels all previous workflow runs for pull requests that have not completed.
+concurrency:
+ # The concurrency group contains the workflow name and the branch name for pull requests
+ # or the commit hash for any other events.
+ group: ${{ github.workflow }}-${{ github.event_name == 'pull_request' && github.head_ref || github.sha }}
+ cancel-in-progress: true
+
</ins><span class="cx" style="display: block; padding: 0 10px"> jobs:
</span><span class="cx" style="display: block; padding: 0 10px"> # Runs the JavaScript coding standards checks.
</span><span class="cx" style="display: block; padding: 0 10px"> #
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -41,16 +46,15 @@
</span><span class="cx" style="display: block; padding: 0 10px"> #
</span><span class="cx" style="display: block; padding: 0 10px"> # Performs the following steps:
</span><span class="cx" style="display: block; padding: 0 10px"> # - Checks out the repository.
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- # - Logs debug information about the runner container.
- # - Installs NodeJS 14.
- # - Sets up caching for NPM.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ # - Logs debug information about the GitHub Action runner.
+ # - Installs NodeJS.
</ins><span class="cx" style="display: block; padding: 0 10px"> # - Logs updated debug information.
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- # _ Installs NPM dependencies using install-changed to hash the `package.json` file.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ # _ Installs NPM dependencies.
</ins><span class="cx" style="display: block; padding: 0 10px"> # - Run the WordPress JSHint checks.
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- # - todo: Configure Slack notifications for failing tests.
</del><span class="cx" style="display: block; padding: 0 10px"> jshint:
</span><span class="cx" style="display: block; padding: 0 10px"> name: JavaScript coding standards
</span><span class="cx" style="display: block; padding: 0 10px"> runs-on: ubuntu-latest
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ timeout-minutes: 20
</ins><span class="cx" style="display: block; padding: 0 10px"> if: ${{ github.repository == 'WordPress/wordpress-develop' || github.event_name == 'pull_request' }}
</span><span class="cx" style="display: block; padding: 0 10px"> env:
</span><span class="cx" style="display: block; padding: 0 10px"> PUPPETEER_SKIP_CHROMIUM_DOWNLOAD: ${{ true }}
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -57,7 +61,7 @@
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> steps:
</span><span class="cx" style="display: block; padding: 0 10px"> - name: Checkout repository
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f # v2.3.4
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # v3.0.2
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> - name: Log debug information
</span><span class="cx" style="display: block; padding: 0 10px"> run: |
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -67,19 +71,11 @@
</span><span class="cx" style="display: block; padding: 0 10px"> svn --version
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> - name: Install NodeJS
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- uses: actions/setup-node@46071b5c7a2e0c34e49c3cb8a0e792e86e18d5ea # v2.1.5
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ uses: actions/setup-node@eeb10cff27034e7acf239c5d29f62154018672fd # v3.3.0
</ins><span class="cx" style="display: block; padding: 0 10px"> with:
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- node-version: 14
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ node-version-file: '.nvmrc'
+ cache: npm
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- - name: Cache NodeJS modules
- uses: actions/cache@26968a09c0ea4f3e233fdddbafd1166051a095f6 # v2.1.4
- env:
- cache-name: cache-node-modules
- with:
- # npm cache files are stored in `~/.npm` on Linux/macOS
- path: ~/.npm
- key: ${{ runner.os }}-npm-${{ hashFiles('**/package-lock.json') }}
-
</del><span class="cx" style="display: block; padding: 0 10px"> - name: Log debug information
</span><span class="cx" style="display: block; padding: 0 10px"> run: |
</span><span class="cx" style="display: block; padding: 0 10px"> npm --version
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -90,3 +86,16 @@
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> - name: Run JSHint
</span><span class="cx" style="display: block; padding: 0 10px"> run: npm run grunt jshint
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+
+ slack-notifications:
+ name: Slack Notifications
+ uses: WordPress/wordpress-develop/.github/workflows/slack-notifications.yml@trunk
+ needs: [ jshint ]
+ if: ${{ github.repository == 'WordPress/wordpress-develop' && github.event_name != 'pull_request' && always() }}
+ with:
+ calling_status: ${{ needs.jshint.result == 'success' && 'success' || needs.jshint.result == 'cancelled' && 'cancelled' || 'failure' }}
+ secrets:
+ SLACK_GHA_SUCCESS_WEBHOOK: ${{ secrets.SLACK_GHA_SUCCESS_WEBHOOK }}
+ SLACK_GHA_CANCELLED_WEBHOOK: ${{ secrets.SLACK_GHA_CANCELLED_WEBHOOK }}
+ SLACK_GHA_FIXED_WEBHOOK: ${{ secrets.SLACK_GHA_FIXED_WEBHOOK }}
+ SLACK_GHA_FAILURE_WEBHOOK: ${{ secrets.SLACK_GHA_FAILURE_WEBHOOK }}
</ins></span></pre></div>
<a id="branches45githubworkflowsendtoendtestsyml"></a>
<div class="delfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Deleted: branches/4.5/.github/workflows/end-to-end-tests.yml</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- branches/4.5/.github/workflows/end-to-end-tests.yml 2022-06-30 17:18:38 UTC (rev 53615)
+++ branches/4.5/.github/workflows/end-to-end-tests.yml 2022-06-30 17:19:15 UTC (rev 53616)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -1,122 +0,0 @@
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-name: End-to-end Tests
-
-on:
- # The end to end test suite was introduced in WordPress 5.3.
- push:
- branches:
- - master
- - trunk
- - '5.[3-9]'
- - '[6-9].[0-9]'
- tags:
- - '5.[3-9]*'
- - '[6-9].[0-9]*'
- pull_request:
- branches:
- - master
- - trunk
- - '5.[3-9]'
- - '[6-9].[0-9]'
- workflow_dispatch:
-
-env:
- LOCAL_DIR: build
-
-jobs:
- # Runs the end-to-end test suite.
- #
- # Performs the following steps:
- # - Cancels all previous workflow runs for pull requests that have not completed.
- # - Set environment variables.
- # - Checks out the repository.
- # - Logs debug information about the runner container.
- # - Installs NodeJS 14.
- # - Sets up caching for NPM.
- # _ Installs NPM dependencies using install-changed to hash the `package.json` file.
- # - Builds WordPress to run from the `build` directory.
- # - Starts the WordPress Docker container.
- # - Logs general debug information.
- # - Logs the running Docker containers.
- # - Logs Docker debug information (about both the Docker installation within the runner and the WordPress container).
- # - Install WordPress within the Docker container.
- # - Run the E2E tests.
- # - todo: Configure Slack notifications for failing tests.
- e2e-tests:
- name: E2E Tests
- runs-on: ubuntu-latest
- if: ${{ github.repository == 'WordPress/wordpress-develop' || github.event_name == 'pull_request' }}
-
- steps:
- - name: Cancel previous runs of this workflow (pull requests only)
- if: ${{ github.event_name == 'pull_request' }}
- uses: styfle/cancel-workflow-action@3d86a7cc43670094ac248017207be0295edbc31d # v0.8.0
-
- - name: Configure environment variables
- run: |
- echo "PHP_FPM_UID=$(id -u)" >> $GITHUB_ENV
- echo "PHP_FPM_GID=$(id -g)" >> $GITHUB_ENV
-
- - name: Checkout repository
- uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f # v2.3.4
-
- - name: Log debug information
- run: |
- npm --version
- node --version
- curl --version
- git --version
- svn --version
- php --version
- php -i
- locale -a
-
- - name: Install NodeJS
- uses: actions/setup-node@46071b5c7a2e0c34e49c3cb8a0e792e86e18d5ea # v2.1.5
- with:
- node-version: 14
-
- - name: Cache NodeJS modules
- uses: actions/cache@26968a09c0ea4f3e233fdddbafd1166051a095f6 # v2.1.4
- env:
- cache-name: cache-node-modules
- with:
- # npm cache files are stored in `~/.npm` on Linux/macOS
- path: ~/.npm
- key: ${{ runner.os }}-npm-${{ hashFiles('**/package-lock.json') }}
-
- - name: Install Dependencies
- run: npm ci
-
- - name: Build WordPress
- run: npm run build
-
- - name: Start Docker environment
- run: |
- npm run env:start
-
- - name: General debug information
- run: |
- npm --version
- node --version
- curl --version
- git --version
- svn --version
-
- - name: Log running Docker containers
- run: docker ps -a
-
- - name: Docker debug information
- run: |
- docker -v
- docker-compose -v
- docker-compose run --rm mysql mysql --version
- docker-compose run --rm php php --version
- docker-compose run --rm php php -m
- docker-compose run --rm php php -i
- docker-compose run --rm php locale -a
-
- - name: Install WordPress
- run: npm run env:install
-
- - name: Run E2E tests
- run: npm run test:e2e
</del></span></pre></div>
<a id="branches45githubworkflowsjavascripttestsyml"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: branches/4.5/.github/workflows/javascript-tests.yml</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- branches/4.5/.github/workflows/javascript-tests.yml 2022-06-30 17:18:38 UTC (rev 53615)
+++ branches/4.5/.github/workflows/javascript-tests.yml 2022-06-30 17:19:15 UTC (rev 53616)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -4,7 +4,6 @@
</span><span class="cx" style="display: block; padding: 0 10px"> # JavaScript testing was introduced in WordPress 3.8.
</span><span class="cx" style="display: block; padding: 0 10px"> push:
</span><span class="cx" style="display: block; padding: 0 10px"> branches:
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- - master
</del><span class="cx" style="display: block; padding: 0 10px"> - trunk
</span><span class="cx" style="display: block; padding: 0 10px"> - '3.[89]'
</span><span class="cx" style="display: block; padding: 0 10px"> - '[4-9].[0-9]'
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -13,7 +12,6 @@
</span><span class="cx" style="display: block; padding: 0 10px"> - '[4-9].[0-9]*'
</span><span class="cx" style="display: block; padding: 0 10px"> pull_request:
</span><span class="cx" style="display: block; padding: 0 10px"> branches:
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- - master
</del><span class="cx" style="display: block; padding: 0 10px"> - trunk
</span><span class="cx" style="display: block; padding: 0 10px"> - '3.[89]'
</span><span class="cx" style="display: block; padding: 0 10px"> - '[4-9].[0-9]'
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -32,31 +30,32 @@
</span><span class="cx" style="display: block; padding: 0 10px"> - '.github/workflows/*.yml'
</span><span class="cx" style="display: block; padding: 0 10px"> workflow_dispatch:
</span><span class="cx" style="display: block; padding: 0 10px">
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+# Cancels all previous workflow runs for pull requests that have not completed.
+concurrency:
+ # The concurrency group contains the workflow name and the branch name for pull requests
+ # or the commit hash for any other events.
+ group: ${{ github.workflow }}-${{ github.event_name == 'pull_request' && github.head_ref || github.sha }}
+ cancel-in-progress: true
+
</ins><span class="cx" style="display: block; padding: 0 10px"> jobs:
</span><span class="cx" style="display: block; padding: 0 10px"> # Runs the QUnit tests for WordPress.
</span><span class="cx" style="display: block; padding: 0 10px"> #
</span><span class="cx" style="display: block; padding: 0 10px"> # Performs the following steps:
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- # - Cancels all previous workflow runs for pull requests that have not completed.
</del><span class="cx" style="display: block; padding: 0 10px"> # - Checks out the repository.
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- # - Logs debug information about the runner container.
- # - Installs NodeJS 14.
- # - Sets up caching for NPM.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ # - Logs debug information about the GitHub Action runner.
+ # - Installs NodeJS.
</ins><span class="cx" style="display: block; padding: 0 10px"> # - Logs updated debug information.
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- # _ Installs NPM dependencies using install-changed to hash the `package.json` file.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ # _ Installs NPM dependencies.
</ins><span class="cx" style="display: block; padding: 0 10px"> # - Run the WordPress QUnit tests.
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- # - todo: Configure Slack notifications for failing tests.
</del><span class="cx" style="display: block; padding: 0 10px"> test-js:
</span><span class="cx" style="display: block; padding: 0 10px"> name: QUnit Tests
</span><span class="cx" style="display: block; padding: 0 10px"> runs-on: ubuntu-latest
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ timeout-minutes: 20
</ins><span class="cx" style="display: block; padding: 0 10px"> if: ${{ github.repository == 'WordPress/wordpress-develop' || github.event_name == 'pull_request' }}
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> steps:
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- - name: Cancel previous runs of this workflow (pull requests only)
- if: ${{ github.event_name == 'pull_request' }}
- uses: styfle/cancel-workflow-action@3d86a7cc43670094ac248017207be0295edbc31d # v0.8.0
-
</del><span class="cx" style="display: block; padding: 0 10px"> - name: Checkout repository
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f # v2.3.4
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # v3.0.2
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> - name: Log debug information
</span><span class="cx" style="display: block; padding: 0 10px"> run: |
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -66,19 +65,11 @@
</span><span class="cx" style="display: block; padding: 0 10px"> svn --version
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> - name: Install NodeJS
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- uses: actions/setup-node@46071b5c7a2e0c34e49c3cb8a0e792e86e18d5ea # v2.1.5
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ uses: actions/setup-node@eeb10cff27034e7acf239c5d29f62154018672fd # v3.3.0
</ins><span class="cx" style="display: block; padding: 0 10px"> with:
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- node-version: 14
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ node-version-file: '.nvmrc'
+ cache: npm
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- - name: Cache NodeJS modules
- uses: actions/cache@26968a09c0ea4f3e233fdddbafd1166051a095f6 # v2.1.4
- env:
- cache-name: cache-node-modules
- with:
- # npm cache files are stored in `~/.npm` on Linux/macOS
- path: ~/.npm
- key: ${{ runner.os }}-npm-${{ hashFiles('**/package-lock.json') }}
-
</del><span class="cx" style="display: block; padding: 0 10px"> - name: Log debug information
</span><span class="cx" style="display: block; padding: 0 10px"> run: |
</span><span class="cx" style="display: block; padding: 0 10px"> npm --version
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -89,3 +80,16 @@
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> - name: Run QUnit tests
</span><span class="cx" style="display: block; padding: 0 10px"> run: npm run grunt qunit:compiled
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+
+ slack-notifications:
+ name: Slack Notifications
+ uses: WordPress/wordpress-develop/.github/workflows/slack-notifications.yml@trunk
+ needs: [ test-js ]
+ if: ${{ github.repository == 'WordPress/wordpress-develop' && github.event_name != 'pull_request' && always() }}
+ with:
+ calling_status: ${{ needs.test-js.result == 'success' && 'success' || needs.test-js.result == 'cancelled' && 'cancelled' || 'failure' }}
+ secrets:
+ SLACK_GHA_SUCCESS_WEBHOOK: ${{ secrets.SLACK_GHA_SUCCESS_WEBHOOK }}
+ SLACK_GHA_CANCELLED_WEBHOOK: ${{ secrets.SLACK_GHA_CANCELLED_WEBHOOK }}
+ SLACK_GHA_FIXED_WEBHOOK: ${{ secrets.SLACK_GHA_FIXED_WEBHOOK }}
+ SLACK_GHA_FAILURE_WEBHOOK: ${{ secrets.SLACK_GHA_FAILURE_WEBHOOK }}
</ins></span></pre></div>
<a id="branches45githubworkflowsphpcompatibilityyml"></a>
<div class="delfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Deleted: branches/4.5/.github/workflows/php-compatibility.yml</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- branches/4.5/.github/workflows/php-compatibility.yml 2022-06-30 17:18:38 UTC (rev 53615)
+++ branches/4.5/.github/workflows/php-compatibility.yml 2022-06-30 17:19:15 UTC (rev 53616)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -1,79 +0,0 @@
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">-name: PHP Compatibility
-
-on:
- # PHP compatibility testing was introduced in WordPress 5.5.
- push:
- branches:
- - master
- - trunk
- - '5.[5-9]'
- - '[6-9].[0-9]'
- tags:
- - '5.[5-9]*'
- - '[6-9].[0-9]*'
- pull_request:
- branches:
- - master
- - trunk
- - '5.[5-9]'
- - '[6-9].[0-9]'
- paths:
- # This workflow only scans PHP files.
- - '**.php'
- # These files configure Composer. Changes could affect the outcome.
- - 'composer.*'
- # This file configures PHP Compatibility scanning. Changes could affect the outcome.
- - 'phpcompat.xml.dist'
- # Changes to workflow files should always verify all workflows are successful.
- - '.github/workflows/*.yml'
- workflow_dispatch:
-
-jobs:
-
- # Runs PHP compatibility testing.
- #
- # Violations are reported inline with annotations.
- #
- # Performs the following steps:
- # - Checks out the repository.
- # - Sets up PHP.
- # - Logs debug information about the runner container.
- # - Installs Composer dependencies (use cache if possible).
- # - Make Composer packages available globally.
- # - Logs PHP_CodeSniffer debug information.
- # - Runs the PHP compatibility tests.
- # - todo: Configure Slack notifications for failing scans.
- php-comatibility:
- name: Check PHP compatibility
- runs-on: ubuntu-latest
- if: ${{ github.repository == 'WordPress/wordpress-develop' || github.event_name == 'pull_request' }}
-
- steps:
- - name: Checkout repository
- uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f # v2.3.4
-
- - name: Set up PHP
- uses: shivammathur/setup-php@afefcaf556d98dc7896cca380e181decb609ca44 # v2.10.0
- with:
- php-version: '7.4'
- coverage: none
- tools: composer, cs2pr
-
- - name: Log debug information
- run: |
- php --version
- composer --version
-
- - name: Install Composer dependencies
- uses: ramsey/composer-install@92a7904348d4ad30236f3611e33b7f0c6f9edd70 # v1.1.0
- with:
- composer-options: "--no-progress --no-ansi --no-interaction"
-
- - name: Make Composer packages available globally
- run: echo "${PWD}/vendor/bin" >> $GITHUB_PATH
-
- - name: Log PHPCS debug information
- run: phpcs -i
-
- - name: Run PHP compatibility tests
- run: phpcs --standard=phpcompat.xml.dist -q --report=checkstyle | cs2pr
</del></span></pre></div>
<a id="branches45githubworkflowsphpunittestsyml"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: branches/4.5/.github/workflows/phpunit-tests.yml</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- branches/4.5/.github/workflows/phpunit-tests.yml 2022-06-30 17:18:38 UTC (rev 53615)
+++ branches/4.5/.github/workflows/phpunit-tests.yml 2022-06-30 17:19:15 UTC (rev 53616)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -3,7 +3,6 @@
</span><span class="cx" style="display: block; padding: 0 10px"> on:
</span><span class="cx" style="display: block; padding: 0 10px"> push:
</span><span class="cx" style="display: block; padding: 0 10px"> branches:
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- - master
</del><span class="cx" style="display: block; padding: 0 10px"> - trunk
</span><span class="cx" style="display: block; padding: 0 10px"> - '3.[7-9]'
</span><span class="cx" style="display: block; padding: 0 10px"> - '[4-9].[0-9]'
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -12,7 +11,6 @@
</span><span class="cx" style="display: block; padding: 0 10px"> - '[4-9].[0-9]*'
</span><span class="cx" style="display: block; padding: 0 10px"> pull_request:
</span><span class="cx" style="display: block; padding: 0 10px"> branches:
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- - master
</del><span class="cx" style="display: block; padding: 0 10px"> - trunk
</span><span class="cx" style="display: block; padding: 0 10px"> - '3.[7-9]'
</span><span class="cx" style="display: block; padding: 0 10px"> - '[4-9].[0-9]'
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -21,6 +19,13 @@
</span><span class="cx" style="display: block; padding: 0 10px"> schedule:
</span><span class="cx" style="display: block; padding: 0 10px"> - cron: '0 0 * * 0'
</span><span class="cx" style="display: block; padding: 0 10px">
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+# Cancels all previous workflow runs for pull requests that have not completed.
+concurrency:
+ # The concurrency group contains the workflow name and the branch name for pull requests
+ # or the commit hash for any other events.
+ group: ${{ github.workflow }}-${{ github.event_name == 'pull_request' && github.head_ref || github.sha }}
+ cancel-in-progress: true
+
</ins><span class="cx" style="display: block; padding: 0 10px"> env:
</span><span class="cx" style="display: block; padding: 0 10px"> LOCAL_DIR: build
</span><span class="cx" style="display: block; padding: 0 10px"> PUPPETEER_SKIP_CHROMIUM_DOWNLOAD: ${{ true }}
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -36,10 +41,9 @@
</span><span class="cx" style="display: block; padding: 0 10px"> # Performs the following steps:
</span><span class="cx" style="display: block; padding: 0 10px"> # - Cancels all previous workflow runs for pull requests that have not completed.
</span><span class="cx" style="display: block; padding: 0 10px"> # - Checks out the repository.
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- # - Logs debug information about the runner container.
- # - Installs NodeJS 14.
- # - Sets up caching for NPM.
- # _ Installs NPM dependencies using install-changed to hash the `package.json` file.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ # - Logs debug information about the GitHub Action runner.
+ # - Installs NodeJS.
+ # _ Installs NPM dependencies.
</ins><span class="cx" style="display: block; padding: 0 10px"> # - Builds WordPress to run from the `build` directory.
</span><span class="cx" style="display: block; padding: 0 10px"> # - Creates a ZIP file of compiled WordPress.
</span><span class="cx" style="display: block; padding: 0 10px"> # - Uploads ZIP file as an artifact.
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -49,12 +53,8 @@
</span><span class="cx" style="display: block; padding: 0 10px"> if: ${{ github.repository == 'WordPress/wordpress-develop' || github.event_name == 'pull_request' }}
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> steps:
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- - name: Cancel previous runs of this workflow (pull requests only)
- if: ${{ github.event_name == 'pull_request' }}
- uses: styfle/cancel-workflow-action@3d86a7cc43670094ac248017207be0295edbc31d # v0.8.0
-
</del><span class="cx" style="display: block; padding: 0 10px"> - name: Checkout repository
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f # v2.3.4
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # v3.0.2
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> - name: Log debug information
</span><span class="cx" style="display: block; padding: 0 10px"> run: |
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -70,19 +70,11 @@
</span><span class="cx" style="display: block; padding: 0 10px"> locale -a
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> - name: Install NodeJS
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- uses: actions/setup-node@46071b5c7a2e0c34e49c3cb8a0e792e86e18d5ea # v2.1.5
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ uses: actions/setup-node@eeb10cff27034e7acf239c5d29f62154018672fd # v3.3.0
</ins><span class="cx" style="display: block; padding: 0 10px"> with:
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- node-version: 14
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ node-version-file: '.nvmrc'
+ cache: npm
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- - name: Cache NodeJS modules
- uses: actions/cache@26968a09c0ea4f3e233fdddbafd1166051a095f6 # v2.1.4
- env:
- cache-name: cache-node-modules
- with:
- # npm cache files are stored in `~/.npm` on Linux/macOS
- path: ~/.npm
- key: ${{ runner.os }}-npm-${{ hashFiles('**/package-lock.json') }}
-
</del><span class="cx" style="display: block; padding: 0 10px"> - name: Install Dependencies
</span><span class="cx" style="display: block; padding: 0 10px"> run: npm ci
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -90,13 +82,13 @@
</span><span class="cx" style="display: block; padding: 0 10px"> run: npm run build
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> - name: Create ZIP artifact
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- uses: thedoctor0/zip-release@a1afcab9c664c9976ac398fa831eac67bed1eb0e # v0.4.1
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ uses: thedoctor0/zip-release@09336613be18a8208dfa66bd57efafd9e2685657 # v0.6.2
</ins><span class="cx" style="display: block; padding: 0 10px"> with:
</span><span class="cx" style="display: block; padding: 0 10px"> filename: built-wp-${{ github.sha }}.zip
</span><span class="cx" style="display: block; padding: 0 10px"> exclusions: '*.git* /*node_modules/* packagehash.txt'
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> - name: Upload build artifact
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- uses: actions/upload-artifact@e448a9b857ee2131e752b06002bf0e093c65e571 # v2.2.2
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ uses: actions/upload-artifact@3cea5372237819ed00197afe530f5a7ea3e805c8 # v3.1.0
</ins><span class="cx" style="display: block; padding: 0 10px"> with:
</span><span class="cx" style="display: block; padding: 0 10px"> name: built-wp-${{ github.sha }}
</span><span class="cx" style="display: block; padding: 0 10px"> path: built-wp-${{ github.sha }}.zip
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -105,21 +97,20 @@
</span><span class="cx" style="display: block; padding: 0 10px"> # Runs the PHPUnit tests for WordPress.
</span><span class="cx" style="display: block; padding: 0 10px"> #
</span><span class="cx" style="display: block; padding: 0 10px"> # Performs the following steps:
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- # - Set environment variables.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ # - Sets environment variables.
</ins><span class="cx" style="display: block; padding: 0 10px"> # - Sets up the environment variables needed for testing with memcached (if desired).
</span><span class="cx" style="display: block; padding: 0 10px"> # - Downloads the built WordPress artifact from the previous job.
</span><span class="cx" style="display: block; padding: 0 10px"> # - Unzips the artifact.
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- # - Installs NodeJS 14.
- # - Sets up caching for NPM.
- # _ Installs NPM dependencies using install-changed to hash the `package.json` file.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ # - Installs NodeJS.
+ # _ Installs NPM dependencies.
</ins><span class="cx" style="display: block; padding: 0 10px"> # - Configures caching for Composer.
</span><span class="cx" style="display: block; padding: 0 10px"> # _ Installs Composer dependencies (if desired).
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- # - Logs Docker debug information (about both the Docker installation within the runner).
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ # - Logs Docker debug information (about the Docker installation within the runner).
</ins><span class="cx" style="display: block; padding: 0 10px"> # - Starts the WordPress Docker container.
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- # - Starts the memcached server after the Docker network has been created (if desired).
- # - Logs WordPress Docker container debug information.
- # - Logs debug general information.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ # - Starts the Memcached server after the Docker network has been created (if desired).
+ # - Logs general debug information about the runner.
</ins><span class="cx" style="display: block; padding: 0 10px"> # - Logs the running Docker containers.
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ # - Logs debug information from inside the WordPress Docker container.
</ins><span class="cx" style="display: block; padding: 0 10px"> # - Logs debug information about what's installed within the WordPress Docker containers.
</span><span class="cx" style="display: block; padding: 0 10px"> # - Install WordPress within the Docker container.
</span><span class="cx" style="display: block; padding: 0 10px"> # - Run the PHPUnit tests.
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -126,11 +117,11 @@
</span><span class="cx" style="display: block; padding: 0 10px"> # - Checks out the WordPress Test reporter repository.
</span><span class="cx" style="display: block; padding: 0 10px"> # - Reconnect the directory to the Git repository.
</span><span class="cx" style="display: block; padding: 0 10px"> # - Submit the test results to the WordPress.org host test results.
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- # - todo: Configure Slack notifications for failing tests.
</del><span class="cx" style="display: block; padding: 0 10px"> test-php:
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- name: ${{ matrix.php }}${{ matrix.multisite && ' multisite' || '' }}${{ matrix.split_slow && ' slow tests' || '' }} ${{ matrix.memcached && ' with memcached' || '' }} on ${{ matrix.os }}
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ name: ${{ matrix.php }}${{ matrix.multisite && ' multisite' || '' }}${{ matrix.split_slow && ' slow tests' || '' }}${{ matrix.memcached && ' with memcached' || '' }} on ${{ matrix.os }}
</ins><span class="cx" style="display: block; padding: 0 10px"> needs: setup-wordpress
</span><span class="cx" style="display: block; padding: 0 10px"> runs-on: ${{ matrix.os }}
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ timeout-minutes: 20
</ins><span class="cx" style="display: block; padding: 0 10px"> strategy:
</span><span class="cx" style="display: block; padding: 0 10px"> fail-fast: false
</span><span class="cx" style="display: block; padding: 0 10px"> matrix:
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -199,7 +190,7 @@
</span><span class="cx" style="display: block; padding: 0 10px"> echo "PHP_FPM_GID=$(id -g)" >> $GITHUB_ENV
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> - name: Download the built WordPress artifact
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- uses: actions/download-artifact@4a7a711286f30c025902c28b541c10e147a9b843 # v2.0.8
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ uses: actions/download-artifact@fb598a63ae348fa914e94cd0ff38f362e927b741 # v3.0.0
</ins><span class="cx" style="display: block; padding: 0 10px"> with:
</span><span class="cx" style="display: block; padding: 0 10px"> name: built-wp-${{ github.sha }}
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -207,25 +198,17 @@
</span><span class="cx" style="display: block; padding: 0 10px"> run: unzip built-wp-${{ github.sha }}.zip
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> - name: Install NodeJS
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- uses: actions/setup-node@46071b5c7a2e0c34e49c3cb8a0e792e86e18d5ea # v2.1.5
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ uses: actions/setup-node@eeb10cff27034e7acf239c5d29f62154018672fd # v3.3.0
</ins><span class="cx" style="display: block; padding: 0 10px"> with:
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- node-version: 14
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ node-version-file: '.nvmrc'
+ cache: npm
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- - name: Use cached Node modules
- uses: actions/cache@26968a09c0ea4f3e233fdddbafd1166051a095f6 # v2.1.4
- env:
- cache-name: cache-node-modules
- with:
- # npm cache files are stored in `~/.npm` on Linux/macOS
- path: ~/.npm
- key: ${{ runner.os }}-npm-${{ hashFiles('**/package-lock.json') }}
-
</del><span class="cx" style="display: block; padding: 0 10px"> - name: Install Dependencies
</span><span class="cx" style="display: block; padding: 0 10px"> run: npm ci
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> - name: Cache Composer dependencies
</span><span class="cx" style="display: block; padding: 0 10px"> if: ${{ env.COMPOSER_INSTALL == true }}
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- uses: actions/cache@26968a09c0ea4f3e233fdddbafd1166051a095f6 # v2.1.4
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ uses: actions/cache@c3f1317a9e7b1ef106c153ac8c0f00fed3ddbc0d # v3.0.4
</ins><span class="cx" style="display: block; padding: 0 10px"> env:
</span><span class="cx" style="display: block; padding: 0 10px"> cache-name: cache-composer-dependencies
</span><span class="cx" style="display: block; padding: 0 10px"> with:
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -305,22 +288,35 @@
</span><span class="cx" style="display: block; padding: 0 10px"> run: npm run test:${{ env.PHPUNIT_SCRIPT }} -- --verbose -c phpunit.xml.dist --group external-http
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> - name: Checkout the WordPress Test Reporter
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- if: ${{ github.repository == 'WordPress/wordpress-develop' && github.ref == 'refs/heads/master' && matrix.report }}
- uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f # v2.3.4
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ if: ${{ github.repository == 'WordPress/wordpress-develop' && github.ref == 'refs/heads/trunk' && matrix.report }}
+ uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # v3.0.2
</ins><span class="cx" style="display: block; padding: 0 10px"> with:
</span><span class="cx" style="display: block; padding: 0 10px"> repository: 'WordPress/phpunit-test-runner'
</span><span class="cx" style="display: block; padding: 0 10px"> path: 'test-runner'
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> - name: Set up the Git repository
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- if: ${{ github.repository == 'WordPress/wordpress-develop' && github.ref == 'refs/heads/master' && matrix.report }}
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ if: ${{ github.repository == 'WordPress/wordpress-develop' && github.ref == 'refs/heads/trunk' && matrix.report }}
</ins><span class="cx" style="display: block; padding: 0 10px"> run: |
</span><span class="cx" style="display: block; padding: 0 10px"> git init
</span><span class="cx" style="display: block; padding: 0 10px"> git remote add origin https://github.com/WordPress/wordpress-develop.git
</span><span class="cx" style="display: block; padding: 0 10px"> git fetch
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- git reset origin/master
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ git reset origin/trunk
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> - name: Submit test results to the WordPress.org host test results
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- if: ${{ github.repository == 'WordPress/wordpress-develop' && github.ref == 'refs/heads/master' && matrix.report }}
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ if: ${{ github.repository == 'WordPress/wordpress-develop' && github.ref == 'refs/heads/trunk' && matrix.report }}
</ins><span class="cx" style="display: block; padding: 0 10px"> env:
</span><span class="cx" style="display: block; padding: 0 10px"> WPT_REPORT_API_KEY: "${{ secrets.WPT_REPORT_API_KEY }}"
</span><span class="cx" style="display: block; padding: 0 10px"> run: docker-compose run --rm -e WPT_REPORT_API_KEY -e WPT_PREPARE_DIR=/var/www -e WPT_TEST_DIR=/var/www php php test-runner/report.php
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+
+ slack-notifications:
+ name: Slack Notifications
+ uses: WordPress/wordpress-develop/.github/workflows/slack-notifications.yml@trunk
+ needs: [ setup-wordpress, test-php ]
+ if: ${{ github.repository == 'WordPress/wordpress-develop' && github.event_name != 'pull_request' && always() }}
+ with:
+ calling_status: ${{ needs.test-php.result == 'success' && 'success' || needs.test-php.result == 'cancelled' && 'cancelled' || 'failure' }}
+ secrets:
+ SLACK_GHA_SUCCESS_WEBHOOK: ${{ secrets.SLACK_GHA_SUCCESS_WEBHOOK }}
+ SLACK_GHA_CANCELLED_WEBHOOK: ${{ secrets.SLACK_GHA_CANCELLED_WEBHOOK }}
+ SLACK_GHA_FIXED_WEBHOOK: ${{ secrets.SLACK_GHA_FIXED_WEBHOOK }}
+ SLACK_GHA_FAILURE_WEBHOOK: ${{ secrets.SLACK_GHA_FAILURE_WEBHOOK }}
</ins></span></pre></div>
<a id="branches45githubworkflowstestnpmyml"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: branches/4.5/.github/workflows/test-npm.yml</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- branches/4.5/.github/workflows/test-npm.yml 2022-06-30 17:18:38 UTC (rev 53615)
+++ branches/4.5/.github/workflows/test-npm.yml 2022-06-30 17:19:15 UTC (rev 53616)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -3,13 +3,11 @@
</span><span class="cx" style="display: block; padding: 0 10px"> on:
</span><span class="cx" style="display: block; padding: 0 10px"> push:
</span><span class="cx" style="display: block; padding: 0 10px"> branches:
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- - master
</del><span class="cx" style="display: block; padding: 0 10px"> - trunk
</span><span class="cx" style="display: block; padding: 0 10px"> - '3.[7-9]'
</span><span class="cx" style="display: block; padding: 0 10px"> - '[4-9].[0-9]'
</span><span class="cx" style="display: block; padding: 0 10px"> pull_request:
</span><span class="cx" style="display: block; padding: 0 10px"> branches:
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- - master
</del><span class="cx" style="display: block; padding: 0 10px"> - trunk
</span><span class="cx" style="display: block; padding: 0 10px"> - '3.[7-9]'
</span><span class="cx" style="display: block; padding: 0 10px"> - '[4-9].[0-9]'
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -25,39 +23,31 @@
</span><span class="cx" style="display: block; padding: 0 10px"> - '.github/workflows/**.yml'
</span><span class="cx" style="display: block; padding: 0 10px"> workflow_dispatch:
</span><span class="cx" style="display: block; padding: 0 10px">
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+# Cancels all previous workflow runs for pull requests that have not completed.
+concurrency:
+ # The concurrency group contains the workflow name and the branch name for pull requests
+ # or the commit hash for any other events.
+ group: ${{ github.workflow }}-${{ github.event_name == 'pull_request' && github.head_ref || github.sha }}
+ cancel-in-progress: true
+
</ins><span class="cx" style="display: block; padding: 0 10px"> env:
</span><span class="cx" style="display: block; padding: 0 10px"> PUPPETEER_SKIP_CHROMIUM_DOWNLOAD: ${{ true }}
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> jobs:
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- # Prepares the workflow.
- #
- # Performs the following steps:
- # - Cancels all previous workflow runs for pull requests that have not completed.
- prepare-workflow:
- name: Prepare the workflow
- runs-on: ubuntu-latest
- if: ${{ github.repository == 'WordPress/wordpress-develop' || github.event_name == 'pull_request' }}
-
- steps:
- - name: Cancel previous runs of this workflow (pull requests only)
- if: ${{ github.event_name == 'pull_request' }}
- uses: styfle/cancel-workflow-action@3d86a7cc43670094ac248017207be0295edbc31d # v0.8.0
-
</del><span class="cx" style="display: block; padding: 0 10px"> # Verifies that installing NPM dependencies and building WordPress works as expected.
</span><span class="cx" style="display: block; padding: 0 10px"> #
</span><span class="cx" style="display: block; padding: 0 10px"> # Performs the following steps:
</span><span class="cx" style="display: block; padding: 0 10px"> # - Checks out the repository.
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- # - Logs debug information about the runner container.
- # - Installs NodeJS 14.
- # - Sets up caching for NPM.
- # _ Installs NPM dependencies using install-changed to hash the `package.json` file.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ # - Logs debug information about the GitHub Action runner.
+ # - Installs NodeJS.
+ # _ Installs NPM dependencies.
</ins><span class="cx" style="display: block; padding: 0 10px"> # - Builds WordPress to run from the `build` directory.
</span><span class="cx" style="display: block; padding: 0 10px"> # - Cleans up after building WordPress to the `build` directory.
</span><span class="cx" style="display: block; padding: 0 10px"> test-npm:
</span><span class="cx" style="display: block; padding: 0 10px"> name: Test NPM on ${{ matrix.os }}
</span><span class="cx" style="display: block; padding: 0 10px"> runs-on: ${{ matrix.os }}
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ timeout-minutes: 20
</ins><span class="cx" style="display: block; padding: 0 10px"> if: ${{ github.repository == 'WordPress/wordpress-develop' || github.event_name == 'pull_request' }}
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- needs: prepare-workflow
</del><span class="cx" style="display: block; padding: 0 10px"> strategy:
</span><span class="cx" style="display: block; padding: 0 10px"> fail-fast: false
</span><span class="cx" style="display: block; padding: 0 10px"> matrix:
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -65,7 +55,7 @@
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> steps:
</span><span class="cx" style="display: block; padding: 0 10px"> - name: Checkout repository
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f # v2.3.4
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # v3.0.2
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> - name: Log debug information
</span><span class="cx" style="display: block; padding: 0 10px"> run: |
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -76,29 +66,11 @@
</span><span class="cx" style="display: block; padding: 0 10px"> svn --version
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> - name: Install NodeJS
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- uses: actions/setup-node@46071b5c7a2e0c34e49c3cb8a0e792e86e18d5ea # v2.1.5
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ uses: actions/setup-node@eeb10cff27034e7acf239c5d29f62154018672fd # v3.3.0
</ins><span class="cx" style="display: block; padding: 0 10px"> with:
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- node-version: 14
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ node-version-file: '.nvmrc'
+ cache: npm
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- - name: Cache NodeJS modules (Ubuntu & MacOS)
- uses: actions/cache@26968a09c0ea4f3e233fdddbafd1166051a095f6 # v2.1.4
- if: ${{ matrix.os != 'windows-latest' }}
- with:
- path: ~/.npm
- key: ${{ runner.os }}-npm-${{ hashFiles('**/package-lock.json') }}
-
- - name: Get NPM cache directory (Windows only)
- if: ${{ matrix.os == 'windows-latest' }}
- id: npm-cache
- run: echo "::set-output name=dir::$(npm config get cache)"
-
- - name: Cache NodeJS modules (Windows only)
- uses: actions/cache@26968a09c0ea4f3e233fdddbafd1166051a095f6 # v2.1.4
- if: ${{ matrix.os == 'windows-latest' }}
- with:
- path: ${{ steps.npm-cache.outputs.dir }}
- key: ${{ runner.os }}-npm-${{ hashFiles('**/package-lock.json') }}
-
</del><span class="cx" style="display: block; padding: 0 10px"> - name: Install Dependencies
</span><span class="cx" style="display: block; padding: 0 10px"> run: npm ci
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -110,14 +82,14 @@
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> # Verifies that installing NPM dependencies and building WordPress works as expected on MacOS.
</span><span class="cx" style="display: block; padding: 0 10px"> #
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- # This is a separate job in order to that more strict conditions can be used.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ # This is separate from the job above in order to use stricter conditions about when to run.
+ # This avoids unintentionally consuming excessive minutes, as MacOS jobs consume minutes at a 10x rate.
</ins><span class="cx" style="display: block; padding: 0 10px"> #
</span><span class="cx" style="display: block; padding: 0 10px"> # Performs the following steps:
</span><span class="cx" style="display: block; padding: 0 10px"> # - Checks out the repository.
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- # - Logs debug information about the runner container.
- # - Installs NodeJS 14.
- # - Sets up caching for NPM.
- # _ Installs NPM dependencies using install-changed to hash the `package.json` file.
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ # - Logs debug information about the GitHub Action runner.
+ # - Installs NodeJS.
+ # _ Installs NPM dependencies.
</ins><span class="cx" style="display: block; padding: 0 10px"> # - Builds WordPress to run from the `build` directory.
</span><span class="cx" style="display: block; padding: 0 10px"> # - Cleans up after building WordPress to the `build` directory.
</span><span class="cx" style="display: block; padding: 0 10px"> test-npm-macos:
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -124,10 +96,9 @@
</span><span class="cx" style="display: block; padding: 0 10px"> name: Test NPM on MacOS
</span><span class="cx" style="display: block; padding: 0 10px"> runs-on: macos-latest
</span><span class="cx" style="display: block; padding: 0 10px"> if: ${{ github.repository == 'WordPress/wordpress-develop' }}
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- needs: prepare-workflow
</del><span class="cx" style="display: block; padding: 0 10px"> steps:
</span><span class="cx" style="display: block; padding: 0 10px"> - name: Checkout repository
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- uses: actions/checkout@5a4ac9002d0be2fb38bd78e4b4dbde5606d7042f # v2.3.4
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ uses: actions/checkout@2541b1294d2704b0964813337f33b291d3f8596b # v3.0.2
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> - name: Log debug information
</span><span class="cx" style="display: block; padding: 0 10px"> run: |
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -138,17 +109,11 @@
</span><span class="cx" style="display: block; padding: 0 10px"> svn --version
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> - name: Install NodeJS
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- uses: actions/setup-node@46071b5c7a2e0c34e49c3cb8a0e792e86e18d5ea # v2.1.5
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ uses: actions/setup-node@eeb10cff27034e7acf239c5d29f62154018672fd # v3.3.0
</ins><span class="cx" style="display: block; padding: 0 10px"> with:
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- node-version: 14
</del><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ node-version-file: '.nvmrc'
+ cache: npm
</ins><span class="cx" style="display: block; padding: 0 10px">
</span><del style="background-color: #fdd; text-decoration:none; display:block; padding: 0 10px">- - name: Cache NodeJS modules
- uses: actions/cache@26968a09c0ea4f3e233fdddbafd1166051a095f6 # v2.1.4
- if: ${{ matrix.os != 'windows-latest' }}
- with:
- path: ~/.npm
- key: ${{ runner.os }}-npm-${{ hashFiles('**/package-lock.json') }}
-
</del><span class="cx" style="display: block; padding: 0 10px"> - name: Install Dependencies
</span><span class="cx" style="display: block; padding: 0 10px"> run: npm ci
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -157,3 +122,16 @@
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> - name: Clean after building
</span><span class="cx" style="display: block; padding: 0 10px"> run: npm run grunt clean
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+
+ slack-notifications:
+ name: Slack Notifications
+ uses: WordPress/wordpress-develop/.github/workflows/slack-notifications.yml@trunk
+ needs: [ test-npm, test-npm-macos ]
+ if: ${{ github.repository == 'WordPress/wordpress-develop' && github.event_name != 'pull_request' && always() }}
+ with:
+ calling_status: ${{ needs.test-npm.result == 'success' && needs.test-npm-macos.result == 'success' && 'success' || ( needs.test-npm.result == 'cancelled' || needs.test-npm-macos.result == 'cancelled' ) && 'cancelled' || 'failure' }}
+ secrets:
+ SLACK_GHA_SUCCESS_WEBHOOK: ${{ secrets.SLACK_GHA_SUCCESS_WEBHOOK }}
+ SLACK_GHA_CANCELLED_WEBHOOK: ${{ secrets.SLACK_GHA_CANCELLED_WEBHOOK }}
+ SLACK_GHA_FIXED_WEBHOOK: ${{ secrets.SLACK_GHA_FIXED_WEBHOOK }}
+ SLACK_GHA_FAILURE_WEBHOOK: ${{ secrets.SLACK_GHA_FAILURE_WEBHOOK }}
</ins></span></pre></div>
<a id="branches45githubworkflowswelcomenewcontributorsyml"></a>
<div class="modfile"><h4 style="background-color: #eee; color: inherit; margin: 1em 0; padding: 1.3em; font-size: 115%">Modified: branches/4.5/.github/workflows/welcome-new-contributors.yml</h4>
<pre class="diff"><span>
<span class="info" style="display: block; padding: 0 10px; color: #888">--- branches/4.5/.github/workflows/welcome-new-contributors.yml 2022-06-30 17:18:38 UTC (rev 53615)
+++ branches/4.5/.github/workflows/welcome-new-contributors.yml 2022-06-30 17:19:15 UTC (rev 53616)
</span><span class="lines" style="display: block; padding: 0 10px; color: #888">@@ -8,6 +8,7 @@
</span><span class="cx" style="display: block; padding: 0 10px"> # Comments on a pull request when the author is a new contributor.
</span><span class="cx" style="display: block; padding: 0 10px"> post-welcome-message:
</span><span class="cx" style="display: block; padding: 0 10px"> runs-on: ubuntu-latest
</span><ins style="background-color: #dfd; text-decoration:none; display:block; padding: 0 10px">+ timeout-minutes: 5
</ins><span class="cx" style="display: block; padding: 0 10px"> if: ${{ github.repository == 'WordPress/wordpress-develop' }}
</span><span class="cx" style="display: block; padding: 0 10px">
</span><span class="cx" style="display: block; padding: 0 10px"> steps:
</span></span></pre>
</div>
</div>
</body>
</html>