Skip to content

Commit

Permalink
change blackfire file
Browse files Browse the repository at this point in the history
  • Loading branch information
DavidBadura committed Dec 29, 2023
1 parent 14b2637 commit 009a3d9
Showing 1 changed file with 12 additions and 8 deletions.
20 changes: 12 additions & 8 deletions tests/Benchmark/blackfire.php
Original file line number Diff line number Diff line change
Expand Up @@ -44,11 +44,15 @@

$schemaDirector->create();

$id = ProfileId::generate();
$profile = Profile::create($id, 'Peter');

for ($i = 0; $i < 10_000; $i++) {
$profile->changeName('Peter ' . $i);
}

$repository->save($profile);
$store->transactional(static function () use ($repository): void {
for ($i = 0; $i < 10_000; $i++) {
$id = ProfileId::generate();
$profile = Profile::create($id, 'Peter');

for ($j = 0; $j < 10; $j++) {
$profile->changeName('Peter ' . $j);
}

$repository->save($profile);
}
});

0 comments on commit 009a3d9

Please sign in to comment.