Build/Test Tools: Backport GitHub Action and build improvements to the 5.5 branch.
This backports several build and test tool improvements to the 5.5 branch. Most notably, this includes:
- The changes required to allow each workflow to be triggered by the `workflow_dispatch` event so that tests can be run on a schedule [50590].
- The ability to run PHPUnit tests from `src` instead of `build` [50441-50443].
- Splitting single site and multisite tests into parallel jobs [50379].
- Split slow tests into separate, parallel jobs for PHP 5.6 [50444].
- Better branch and path scoping for GitHub Action workflows when running on `pull_request` [50432,50479].
- Several `devDependency` updates.
Merges [50267,50299,50379,50387,50413,50416,50432,50435-50436,50441-50444,50446,50473-50474,50476,50479,50485-50487,50545,50579,50590,50592,50598] to the 5.5 branch.
See #50401, #51734, #51801, #51802, #52548, #52608, #52612, #52623, #52624, #52625, #52645, #52653, #52658, #52660, #52667, #52786.
Built from https://develop.svn.wordpress.org/branches/5.5@50603
git-svn-id: http://core.svn.wordpress.org/branches/5.5@50216 1a063a9b-81f0-0310-95a4-ce76da25c4cd
2021-03-26 18:49:17 +01:00
|
|
|
!function(d){var n={add:"ajaxAdd",del:"ajaxDel",dim:"ajaxDim",process:"process",recolor:"recolor"},c={settings:{url:ajaxurl,type:"POST",response:"ajax-response",what:"",alt:"alternate",altOffset:0,addColor:"#ffff33",delColor:"#faafaa",dimAddColor:"#ffff33",dimDelColor:"#ff3333",confirm:null,addBefore:null,addAfter:null,delBefore:null,delAfter:null,dimBefore:null,dimAfter:null},nonce:function(e,t){var n=wpAjax.unserialize(e.attr("href")),e=d("#"+t.element);return t.nonce||n._ajax_nonce||e.find('input[name="_ajax_nonce"]').val()||n._wpnonce||e.find('input[name="_wpnonce"]').val()||0},parseData:function(e,t){var n,o=[];try{(n=(n=d(e).data("wp-lists")||"").match(new RegExp(t+":[\\S]+")))&&(o=n[0].split(":"))}catch(e){}return o},pre:function(e,t,n){var o,i;return t=d.extend({},this.wpList.settings,{element:null,nonce:0,target:e.get(0)},t||{}),!(d.isFunction(t.confirm)&&(o=d("#"+t.element),"add"!==n&&(i=o.css("backgroundColor"),o.css("backgroundColor","#ff9966")),e=t.confirm.call(this,e,t,n,i),"add"!==n&&o.css("backgroundColor",i),!e))&&t},ajaxAdd:function(e,n){var o,i,t=this,s=d(e),e=c.parseData(s,"add");return(n=c.pre.call(t,s,n=n||{},"add")).element=e[2]||s.prop("id")||n.element||null,n.addColor=e[3]?"#"+e[3]:n.addColor,!!n&&(s.is('[id="'+n.element+'-submit"]')?!n.element||(n.action="add-"+n.what,n.nonce=c.nonce(s,n),!!wpAjax.validateForm("#"+n.element)&&(n.data=d.param(d.extend({_ajax_nonce:n.nonce,action:n.action},wpAjax.unserialize(e[4]||""))),e=d("#"+n.element+" :input").not('[name="_ajax_nonce"], [name="_wpnonce"], [name="action"]'),(e=d.isFunction(e.fieldSerialize)?e.fieldSerialize():e.serialize())&&(n.data+="&"+e),!(!d.isFunction(n.addBefore)||(n=n.addBefore(n)))||(!n.data.match(/_ajax_nonce=[a-f0-9]+/)||(n.success=function(e){return o=wpAjax.parseAjaxResponse(e,n.response,n.element),i=e,!(!o||o.errors)&&(!0===o||(d.each(o.responses,function(){c.add.call(t,this.data,d.extend({},n,{position:this.position||0,id:this.id||0,oldId:this.oldId||null}))}),t.wpList.recolor(),d(t).trigger("wpListAddEnd",[n,t.wpList]),void c.clear.call(t,"#"+n.element)))},n.complete=function(e,t){d.isFunction(n.addAfter)&&n.addAfter(i,d.extend({xml:e,status:t,parsed:o},n))},d.ajax(n),!1)))):!c.add.call(t,s,n))},ajaxDel:function(e,n){var o,i,s,t=this,a=d(e),e=c.parseData(a,"delete");return(n=c.pre.call(t,a,n=n||{},"delete")).element=e[2]||n.element||null,n.delColor=e[3]?"#"+e[3]:n.delColor,!(!n||!n.element)&&(n.action="delete-"+n.what,n.nonce=c.nonce(a,n),n.data=d.extend({_ajax_nonce:n.nonce,action:n.action,id:n.element.split("-").pop()},wpAjax.unserialize(e[4]||"")),!(!d.isFunction(n.delBefore)||(n=n.delBefore(n,t)))||(!n.data._ajax_nonce||(o=d("#"+n.element),"none"!==n.delColor?o.css("backgroundColor",n.delColor).fadeOut(350,function(){t.wpList.recolor(),d(t).trigger("wpListDelEnd",[n,t.wpList])}):(t.wpList.recolor(),d(t).trigger("wpListDelEnd",[n,t.wpList])),n.success=function(e){if(i=wpAjax.parseAjaxResponse(e,n.response,n.element),s=e,!i||i.errors)return o.stop().stop().css("backgroundColor","#faa").show().queue(function(){t.wpList.recolor(),d(this).dequeue()}),!1},n.complete=function(e,t){d.isFunction(n.delAfter)&&o.queue(function(){n.delAfter(s,d.extend({xml:e,status:t,parsed:i},n))}).dequeue()},d.ajax(n),!1)))},ajaxDim:function(e,n){var o,i,s,a,l=this,r=d(e),t=c.parseData(r,"dim");return"none"!==r.parent().css("display")&&((n=c.pre.call(l,r,n=n||{},"dim")).element=t[2]||n.element||null,n.dimClass=t[3]||n.dimClass||null,n.dimAddColor=t[4]?"#"+t[4]:n.dimAddColor,n.dimDelColor=t[5]?"#"+t[5]:n.dimDelColor,!(n&&n.element&&n.dimClass)||(n.action="dim-"+n.what,n.nonce=c.nonce(r,n),n.data=d.extend({_ajax_nonce:n.nonce,action:n.action,id:n.element.split("-").pop(),dimClass:n.dimClass},wpAjax.unserialize(t[6]||"")),!(!d.isFunction(n.dimBefore)||(n=n.dimBefore(n)))||(o=d("#"+n.element),i=o.toggleClass(n.dimClass).is("."+n.dimClass),e=c.getColor(o),t=i?n.dimAddColor:n.dimDelColor,o.toggleClass(n.dimClass),"none"!==t?o.animate({backgroundColor:t},"fast").queue(function(){o.toggleClass(n.dimClass),d(this).dequeue()}).animate({backgroundColor:e},{comp
|