Make WordPress Core

Ticket #52666: 52666.diff

File 52666.diff, 3.3 KB (added by SergeyBiryukov, 4 years ago)
  • Gruntfile.js

     
    16161617                var done = this.async();
    16171618                var flags = this.flags;
    16181619                var args = changedFiles.php;
    1619                 if ( flags.travisErrors ) {
    1620                         // We can check the entire codebase for coding standards errors.
    1621                         args = [ 'lint:errors' ];
    1622                 } else if ( flags.travisWarnings ) {
    1623                         // We can check the tests directory for errors and warnings.
    1624                         args = [ 'lint', 'tests' ];
    1625                 } else {
    1626                         args.unshift( 'lint' );
    1627                 }
     1620
     1621                args.unshift( 'lint' );
     1622
    16281623                grunt.util.spawn( {
    16291624                        cmd: 'composer',
    16301625                        args: args,
     
    16381633                } );
    16391634        } );
    16401635
    1641         // Travis CI tasks.
    1642         grunt.registerTask('travis:js', 'Runs JavaScript Travis CI tasks.', [ 'jshint:corejs', 'qunit:compiled' ]);
    1643         grunt.registerTask('travis:phpunit', 'Runs PHPUnit Travis CI tasks.', [ 'build', 'phpunit' ]);
    1644         grunt.registerTask('travis:phpcs', 'Runs PHP Coding Standards Travis CI tasks.', [ 'format:php:error', 'lint:php:travisErrors:error', 'lint:php:travisWarnings:error' ]);
    1645 
    16461636        // Patch task.
    16471637        grunt.renameTask('patch_wordpress', 'patch');
    16481638
  • README.md

     
    11# WordPress
    22
    3 [![Build Status](https://img.shields.io/travis/com/WordPress/wordpress-develop/master.svg)](https://travis-ci.com/WordPress/wordpress-develop)
    4 
    53Welcome to the WordPress development repository! Please check out the [contributor handbook](https://make.wordpress.org/core/handbook/) for information about how to open bug reports, contribute patches, test changes, write documentation, or get involved in any way you can.
    64
    75* [Getting Started](#getting-started)
  • tests/phpunit/includes/abstract-testcase.php

     
    181181        /**
    182182         * Allow tests to be skipped on some automated runs.
    183183         *
    184          * For test runs on Travis/GitHub Actions for something other than trunk/master,
     184         * For test runs on GitHub Actions for something other than trunk/master,
    185185         * we want to skip tests that only need to run for master.
    186186         */
    187187        public function skipOnAutomatedBranches() {
    188                 // https://docs.travis-ci.com/user/environment-variables/#Default-Environment-Variables
    189                 $travis_branch       = getenv( 'TRAVIS_BRANCH' );
    190                 $travis_pull_request = getenv( 'TRAVIS_PULL_REQUEST' );
    191 
    192188                // https://docs.github.com/en/free-pro-team@latest/actions/reference/environment-variables#default-environment-variables
    193189                $github_event_name = getenv( 'GITHUB_EVENT_NAME' );
    194190                $github_ref        = getenv( 'GITHUB_REF' );
     
    200196                        if ( in_array( $github_event_name, $skipped, true ) || 'refs/heads/master' !== $github_ref ) {
    201197                                $this->markTestSkipped( 'For automated test runs, this test is only run on trunk/master' );
    202198                        }
    203                 } elseif ( $travis_branch && 'false' !== $travis_branch ) {
    204                         // We're on Travis CI.
    205                         if ( 'master' !== $travis_branch || 'false' !== $travis_pull_request ) {
    206                                 $this->markTestSkipped( 'For automated test runs, this test is only run on trunk/master' );
    207                         }
    208199                }
    209200        }
    210201