Skip to:
Content

bbPress.org

Changeset 6217


Ignore:
Timestamp:
01/12/2017 07:04:27 AM (5 years ago)
Author:
netweb
Message:

Unit Tests: Don't run BuddyPress PHPUnit tests on PHP 5.2.x

Previously r6204 attempted to skip BuddyPress tests if the PHP version was less than 5.3.0, this didn't work as intended as BuddyPress was still being loaded, the change would have only skipped tests rather than completely excluding the BuddyPress PHPUnit test suite from running on PHP versions less than 5.3.0.

This changeset reverts r6204 and separates the grunt test tasks into individual WordPress and BuddyPress PHPUnit Grunt tasks, this gives us the ability to explicitly exclude BuddyPress PHPUnit test suite from running on PHP 5.2.

See also https://bpdevel.wordpress.com/2016/07/21/php-5-2-bp-2-8-and-php-support-guidelines/

Fixes #3037.

Location:
trunk
Files:
3 edited

Legend:

Unmodified
Added
Removed
  • trunk/.travis.yml

    r6203 r6217  
    9090script:
    9191  - grunt travis
     92  - if [ "$TRAVIS_PHP_VERSION" != "5.2" ]; then grunt test:buddypress; fi
    9293
    9394notifications:
  • trunk/Gruntfile.js

    r6100 r6217  
    409409
    410410    // PHPUnit test task.
    411     grunt.registerTask( 'test', 'Run all PHPUnit test tasks.', [ 'phpunit' ] );
     411    grunt.registerTask( 'test:buddypress', 'Run the BuddyPress PHPUnit test tasks.', [ 'phpunit:buddypress' ] );
     412    grunt.registerTask( 'test:wordpress', 'Run the single and multisite WordPress PHPUnit test tasks.', [ 'phpunit:default', 'phpunit:multisite' ] );
     413
     414
     415
    412416
    413417    // JavaScript test task.
     
    415419
    416420    // Travis CI Task
    417     grunt.registerTask( 'travis', [ 'jsvalidate:src', 'jshint', 'checktextdomain', 'test' ] );
     421    grunt.registerTask( 'travis', [ 'jsvalidate:src', 'jshint', 'checktextdomain', 'test:wordpress' ] );
    418422
    419423    // Patch task.
  • trunk/tests/phpunit/buddypress.xml

    r6204 r6217  
    1212    <testsuites>
    1313        <testsuite>
    14             <directory suffix=".php" phpVersion="5.3.0" phpVersionOperator=">=">./testcases/</directory>
     14            <directory suffix=".php">./testcases/</directory>
    1515        </testsuite>
    1616    </testsuites>
Note: See TracChangeset for help on using the changeset viewer.