Skip to content

Commit 4f652f3

Browse files
committed
Implement startTest rather than startTestSuite
Passing a TestSuite instance to CoverageListenerTrait::testStart() will have no effect.
1 parent f4fde1e commit 4f652f3

File tree

3 files changed

+9
-9
lines changed

3 files changed

+9
-9
lines changed

Legacy/CoverageListenerForV5.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -12,8 +12,8 @@
1212
namespace Symfony\Bridge\PhpUnit\Legacy;
1313

1414
/**
15-
* CoverageListener adds `@covers <className>` on each test suite when possible
16-
* to make the code coverage more accurate.
15+
* CoverageListener adds `@covers <className>` on each test when possible to
16+
* make the code coverage more accurate.
1717
*
1818
* @author Grégoire Pineau <lyrixx@lyrixx.info>
1919
*

Legacy/CoverageListenerForV6.php

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -15,8 +15,8 @@
1515
use PHPUnit\Framework\Test;
1616

1717
/**
18-
* CoverageListener adds `@covers <className>` on each test suite when possible
19-
* to make the code coverage more accurate.
18+
* CoverageListener adds `@covers <className>` on each test when possible to
19+
* make the code coverage more accurate.
2020
*
2121
* @author Grégoire Pineau <lyrixx@lyrixx.info>
2222
*

Legacy/CoverageListenerForV7.php

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -11,13 +11,13 @@
1111

1212
namespace Symfony\Bridge\PhpUnit\Legacy;
1313

14+
use PHPUnit\Framework\Test;
1415
use PHPUnit\Framework\TestListener;
1516
use PHPUnit\Framework\TestListenerDefaultImplementation;
16-
use PHPUnit\Framework\TestSuite;
1717

1818
/**
19-
* CoverageListener adds `@covers <className>` on each test suite when possible
20-
* to make the code coverage more accurate.
19+
* CoverageListener adds `@covers <className>` on each test when possible to
20+
* make the code coverage more accurate.
2121
*
2222
* @author Grégoire Pineau <lyrixx@lyrixx.info>
2323
*
@@ -34,8 +34,8 @@ public function __construct(callable $sutFqcnResolver = null, $warningOnSutNotFo
3434
$this->trait = new CoverageListenerTrait($sutFqcnResolver, $warningOnSutNotFound);
3535
}
3636

37-
public function startTestSuite(TestSuite $suite): void
37+
public function startTest(Test $test): void
3838
{
39-
$this->trait->startTest($suite);
39+
$this->trait->startTest($test);
4040
}
4141
}

0 commit comments

Comments
 (0)