Skip to content

Commit f52bb42

Browse files
committed
reorganize benchmarks
1 parent 46f03ce commit f52bb42

4 files changed

Lines changed: 3 additions & 2 deletions

File tree

phpbench-bootstrap.php

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ function tests_reset__SERVER() { // phpcs:ignore WordPress.NamingConventions.Val
4444

4545
define( 'WP_TESTS_TABLE_PREFIX', $table_prefix );
4646

47+
define( 'DIR_BENCHMARKDATA', __DIR__ . '/tests/benchmarks/data' );
4748
define( 'DIR_TESTDATA', __DIR__ . '/tests/phpunit/data' );
4849
define( 'WP_LANG_DIR', realpath( DIR_TESTDATA . '/languages' ) );
4950

phpbench.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
{
22
"$schema": "./vendor/phpbench/phpbench/phpbench.schema.json",
33
"runner.bootstrap": "phpbench-bootstrap.php",
4-
"runner.path": "tests/benchmarks"
4+
"runner.path": "tests/benchmarks/benchmarks"
55
}

tests/benchmarks/html-api/WpHtmlTagProcessorBench.php renamed to tests/benchmarks/benchmarks/html-api/WpHtmlTagProcessorBench.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -146,6 +146,6 @@ public function bench_html_full_parsing( array $params ): void {
146146
public static function provide_html(): iterable {
147147
yield 'Empty string' => array( '' );
148148
yield 'Short doc' => array( '<h1>Hello, world!</h1>' );
149-
yield 'HTML Standard' => array( file_get_contents( DIR_TESTDATA . '/html-api/html-standard.html' ) );
149+
yield 'HTML Standard' => array( file_get_contents( DIR_BENCHMARKDATA . '/html-standard.html' ) );
150150
}
151151
}
File renamed without changes.

0 commit comments

Comments
 (0)