mirror of
https://github.com/pestphp/pest.git
synced 2026-04-23 23:47:30 +02:00
feat(tia): adds poc
This commit is contained in:
23
src/Subscribers/EnsureTiaCoverageIsFlushed.php
Normal file
23
src/Subscribers/EnsureTiaCoverageIsFlushed.php
Normal file
@ -0,0 +1,23 @@
|
||||
<?php
|
||||
|
||||
declare(strict_types=1);
|
||||
|
||||
namespace Pest\Subscribers;
|
||||
|
||||
use Pest\Support\Tia\Recorder;
|
||||
use PHPUnit\Event\Test\Finished;
|
||||
use PHPUnit\Event\Test\FinishedSubscriber;
|
||||
|
||||
/**
|
||||
* Stops PCOV collection after each test and merges the covered files into the
|
||||
* TIA recorder's aggregate map. No-op unless the recorder is active.
|
||||
*
|
||||
* @internal
|
||||
*/
|
||||
final class EnsureTiaCoverageIsFlushed implements FinishedSubscriber
|
||||
{
|
||||
public function notify(Finished $event): void
|
||||
{
|
||||
Recorder::instance()->endTest();
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user