diff --git a/.gitignore b/.gitignore index 321962ab6..6b04b15ec 100644 --- a/.gitignore +++ b/.gitignore @@ -2,5 +2,5 @@ build-config.cfg src/style.css src/style.css.map src/scss/.sass-cache -tests/bootstrap.php +tests/bootstrap-config.php .idea \ No newline at end of file diff --git a/tests/bootstrap-config-sample.php b/tests/bootstrap-config-sample.php new file mode 100644 index 000000000..6fd10dd3d --- /dev/null +++ b/tests/bootstrap-config-sample.php @@ -0,0 +1,7 @@ + '/tmp/wordpress-tests-lib' +]; + + ?> \ No newline at end of file diff --git a/tests/bootstrap.php b/tests/bootstrap.php index 01a830ec8..bb2411106 100644 --- a/tests/bootstrap.php +++ b/tests/bootstrap.php @@ -4,9 +4,11 @@ * * @package Test_Tainacan */ +$bootstrap_cfg = require('bootstrap-config.php'); + $_tests_dir = getenv( 'WP_TESTS_DIR' ); if ( ! $_tests_dir ) { - $_tests_dir = '/tmp/wordpress-tests-lib'; + $_tests_dir = $bootstrap_cfg['tests_dir']; } // Give access to tests_add_filter() function. require_once $_tests_dir . '/includes/functions.php';