Skip to content

Commit fd0f7b7

Browse files
authored
Merge pull request #100 from wp-cli/add/wp-cli-testcase
Add centralized test case with polyfills
2 parents eaf01d7 + 3998173 commit fd0f7b7

File tree

2 files changed

+13
-7
lines changed

2 files changed

+13
-7
lines changed

tests/bootstrap.php

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -27,15 +27,9 @@
2727
: '2.x.x'
2828
);
2929

30-
/**
31-
* Compatibility with PHPUnit 6+
32-
*/
33-
if ( class_exists( 'PHPUnit\Runner\Version' ) ) {
34-
require_once __DIR__ . '/phpunit6-compat.php';
35-
}
36-
3730
require_once VENDOR_DIR . '/autoload.php';
3831
require_once WP_CLI_ROOT . '/php/utils.php';
32+
require_once __DIR__ . '/wp-cli-testcase.php';
3933

4034
function wpcli_tests_include_config( array $config_filenames = [] ) {
4135
$config_filename = false;

tests/wp-cli-testcase.php

Lines changed: 12 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,12 @@
1+
<?php
2+
3+
namespace WP_CLI\Tests;
4+
5+
use Yoast\PHPUnitPolyfills\TestCases\TestCase as PolyfilledTestCase;
6+
7+
/**
8+
* WP-CLI base test case.
9+
*/
10+
class TestCase extends PolyfilledTestCase {
11+
12+
}

0 commit comments

Comments
 (0)