Skip to:
Content

BuddyPress.org

Changeset 12552


Ignore:
Timestamp:
02/27/2020 10:30:30 PM (5 years ago)
Author:
imath
Message:

Bump PHP required version to 5.6

This commit also tries to fix failing tests with PHP 7.2

Fixes #8172

Location:
trunk
Files:
1 deleted
4 edited

Legend:

Unmodified
Added
Removed
  • trunk/.travis.yml

    r12492 r12552  
    33# Use new Travis container-based infrastructure
    44# http://docs.travis-ci.com/user/workers/container-based-infrastructure/
    5 sudo: false
     5os: linux
    66
    77language: php
     
    2121php:
    2222  - 7.3
    23   - 7.2
    2423  - 5.6
    2524
     
    4140    - php: 7.3
    4241      env: WP_VERSION=master BP_TRAVISCI=travis:phpcompat
    43     - php: 5.3
    44       env: WP_VERSION=4.8 BP_TRAVISCI=travis:phpunit
     42    - php: 7.2
     43      env: WP_VERSION=master BP_TRAVISCI=travis:phpunit
     44      dist: precise
     45    - php: 7.2
     46      env: WP_VERSION=5.3 BP_TRAVISCI=travis:phpunit
     47      dist: precise
     48    - php: 7.2
     49      env: WP_VERSION=5.2 BP_TRAVISCI=travis:phpunit
     50      dist: precise
     51    - php: 7.2
     52      env: WP_VERSION=5.1 BP_TRAVISCI=travis:phpunit
     53      dist: precise
     54    - php: 7.2
     55      env: WP_VERSION=5.0 BP_TRAVISCI=travis:phpunit
    4556      dist: precise
    4657  exclude:
     
    101112# before_script: Failures in this section will result in build status 'errored'
    102113before_script:
    103   - if [[ ${TRAVIS_PHP_VERSION:0:3} == "5.3" ]]; then composer global require --dev phpunit/phpunit ^4; fi
    104114  - if [[ ${TRAVIS_PHP_VERSION:0:3} == "5.6" ]]; then composer global require --dev phpunit/phpunit ^5; composer install; fi
    105115  - if [[ ${TRAVIS_PHP_VERSION:0:3} == "7.2" ]]; then composer global require --dev phpunit/phpunit ^6; composer install; fi
  • trunk/Gruntfile.js

    r12499 r12552  
    270270        },
    271271        phplint: {
    272             good: ['src/**/*.php', '!src/bp-core/compat/php56/*.php'].concat( BP_EXCLUDED_MISC )
     272            good: ['src/**/*.php'].concat( BP_EXCLUDED_MISC )
    273273        },
    274274        postcss: {
     
    326326            },
    327327            phpcompat: {
    328                 command: './vendor/bin/phpcs -p --standard=PHPCompatibilityWP --extensions=php --runtime-set testVersion 5.3- src tests',
     328                command: './vendor/bin/phpcs -p --standard=PHPCompatibilityWP --extensions=php --runtime-set testVersion 5.6- src tests',
    329329                stdout: true
    330330            },
  • trunk/src/bp-core/classes/class-bp-walker-nav-menu.php

    r12498 r12552  
    1212
    1313/**
    14  * Compatibility Class to make BP_Walker_Nav_Menu::walk() compatible
    15  * from PHP 5.3 to 5.6 and up.
     14 * Create HTML list of BP nav items.
    1615 *
    17  * @since 5.1.0
     16 * @since 1.7.0
    1817 */
    19 class BP_Walker_Nav_Menu_Compat extends Walker_Nav_Menu {
     18class BP_Walker_Nav_Menu extends Walker_Nav_Menu {
    2019    /**
    2120     * Description of fields indexes for building markup.
     
    133132
    134133    /**
     134     * Overrides Walker::walk() method.
     135     *
     136     * @since 6.0.0 Formalized the existing `...$args` parameter by adding it
     137     *              to the function signature to match WordPress 5.3.
     138     *
     139     * @param array $elements  See {@link Walker::walk()}.
     140     * @param int   $max_depth See {@link Walker::walk()}.
     141     * @param mixed ...$args   See {@link Walker::walk()}.
     142     */
     143    public function walk( $elements, $max_depth, ...$args ) {
     144        return $this->do_walk( $elements, $max_depth, $args );
     145    }
     146
     147    /**
    135148     * Display the current <li> that we are on.
    136149     *
     
    213226    }
    214227}
    215 
    216 if ( PHP_VERSION_ID >= 50600 ) {
    217     require_once dirname( __DIR__ ) . '/compat/php56/class-bp-compat-walker-nav-menu.php';
    218 } else {
    219     require_once dirname( __DIR__ ) . '/compat/php53/class-bp-compat-walker-nav-menu.php';
    220 }
  • trunk/src/readme.txt

    r12492 r12552  
    44Requires at least: 4.8
    55Tested up to: 5.2
    6 Requires PHP: 5.3
     6Requires PHP: 5.6
    77Stable tag: 5.0.0
    88License: GPLv2 or later
Note: See TracChangeset for help on using the changeset viewer.