diff --git a/benchmarks/create.php b/benchmarks/create.php new file mode 100644 index 00000000..037c4f74 --- /dev/null +++ b/benchmarks/create.php @@ -0,0 +1,18 @@ +setN( 500000 ); +$bench->setTitle('obj create'); + +$bench->iterate( 'obj create' , 'object construction time' , function() { + $s = new stdClass; +}); + +$bench->iterate( 'model create', 'model create', function() { + $a = new tests\Author; +}); + +$result = $bench->compare(); +echo $result->output('console'); diff --git a/tests/bootstrap.php b/tests/bootstrap.php index 70a495f5..e67a6e39 100644 --- a/tests/bootstrap.php +++ b/tests/bootstrap.php @@ -9,4 +9,5 @@ dirname(__DIR__) . '/tests/schema', 'tests/src' )); +$loader->useIncludePath(true); $loader->register();