Changeset 49535
- Timestamp:
- 11/07/2020 01:18:24 PM (4 years ago)
- Location:
- trunk
- Files:
-
- 3 edited
Legend:
- Unmodified
- Added
- Removed
-
trunk/composer.json
r49306 r49535 17 17 "wp-coding-standards/wpcs": "~2.3.0", 18 18 "phpcompatibility/phpcompatibility-wp": "^2.1.0", 19 "phpunit/phpunit": "^7.5" 19 "phpunit/phpunit": "^7.5", 20 "ext-gd": "*" 20 21 }, 21 22 "autoload-dev": { -
trunk/composer.lock
r49306 r49535 5 5 "This file is @generated automatically" 6 6 ], 7 "content-hash": " 463db2b4afb439fb63d93173c0852e27",7 "content-hash": "fcf040d9233a22165eeffaeb98694436", 8 8 "packages": [], 9 9 "packages-dev": [ … … 131 131 "constructor", 132 132 "instantiate" 133 ], 134 "funding": [ 135 { 136 "url": "https://www.doctrine-project.org/sponsorship.html", 137 "type": "custom" 138 }, 139 { 140 "url": "https://www.patreon.com/phpdoctrine", 141 "type": "patreon" 142 }, 143 { 144 "url": "https://tidelift.com/funding/github/packagist/doctrine%2Finstantiator", 145 "type": "tidelift" 146 } 133 147 ], 134 148 "time": "2020-05-29T17:27:14+00:00" … … 1838 1852 "php": ">=5.6" 1839 1853 }, 1840 "platform-dev": [], 1854 "platform-dev": { 1855 "ext-gd": "*" 1856 }, 1841 1857 "plugin-api-version": "1.1.0" 1842 1858 } -
trunk/tests/phpunit/includes/bootstrap.php
r49491 r49535 38 38 require_once __DIR__ . '/functions.php'; 39 39 40 if ( defined( 'WP_RUN_CORE_TESTS' ) && WP_RUN_CORE_TESTS && ! is_dir( ABSPATH ) ) { 41 echo "Error: The /build/ directory is missing! Please run `npm run build` prior to running PHPUnit.\n"; 42 exit( 1 ); 43 } 44 40 45 $phpunit_version = tests_get_phpunit_version(); 41 46 … … 49 54 } 50 55 51 if ( defined( 'WP_RUN_CORE_TESTS' ) && WP_RUN_CORE_TESTS && ! is_dir( ABSPATH ) ) { 52 echo "Error: The /build/ directory is missing! Please run `npm run build` prior to running PHPUnit.\n"; 56 $required_extensions = array( 57 'gd', 58 ); 59 $missing_extensions = array(); 60 61 foreach ( $required_extensions as $extension ) { 62 if ( ! extension_loaded( $extension ) ) { 63 $missing_extensions[] = $extension; 64 } 65 } 66 67 if ( $missing_extensions ) { 68 printf( 69 "Error: The following required PHP extensions are missing from the testing environment: %s.\n", 70 implode( ', ', $missing_extensions ) 71 ); 72 echo "Please make sure they are installed and enabled.\n", 53 73 exit( 1 ); 54 74 } … … 60 80 'WP_PHP_BINARY', 61 81 ); 82 $missing_constants = array(); 62 83 63 84 foreach ( $required_constants as $constant ) { 64 85 if ( ! defined( $constant ) ) { 65 printf( 66 "Error: The required %s constant is not defined. Check out `wp-tests-config-sample.php` for an example.\n", 67 $constant 68 ); 69 exit( 1 ); 70 } 86 $missing_constants[] = $constant; 87 } 88 } 89 90 if ( $missing_constants ) { 91 printf( 92 "Error: The following required constants are not defined: %s.\n", 93 implode( ', ', $missing_constants ) 94 ); 95 echo "Please check out `wp-tests-config-sample.php` for an example.\n", 96 exit( 1 ); 71 97 } 72 98
Note: See TracChangeset
for help on using the changeset viewer.