Skip to content

Commit a17e789

Browse files
committed
Add missing bootstrap constants WP_CLI and WP_CLI_VERSION
1 parent 0d98561 commit a17e789

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

tests/bootstrap.php

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,5 @@
11
<?php
2+
define( 'WP_CLI', true );
23
define( 'WP_CLI_TESTS_ROOT', dirname( __DIR__ ) );
34
define( 'VENDOR_DIR',
45
file_exists( WP_CLI_TESTS_ROOT . '/vendor/autoload.php' )
@@ -7,6 +8,7 @@
78
);
89
define( 'WP_CLI_ROOT', VENDOR_DIR . '/wp-cli/wp-cli' );
910
define( 'PACKAGE_ROOT', VENDOR_DIR . '/..' );
11+
define( 'WP_CLI_VERSION', trim( file_get_contents( WP_CLI_ROOT . '/VERSION' ) ) );
1012

1113
/**
1214
* Compatibility with PHPUnit 6+

0 commit comments

Comments
 (0)