Skip to content

Commit 1ac1693

Browse files
committed
Drop PHP 7.3
1 parent 5e29262 commit 1ac1693

File tree

7 files changed

+9
-42
lines changed

7 files changed

+9
-42
lines changed

.github/workflows/ci.yml

-5
Original file line numberDiff line numberDiff line change
@@ -20,7 +20,6 @@ jobs:
2020
- "8.1"
2121
- "8.0"
2222
- "7.4"
23-
- "7.3"
2423

2524
php-code-coverage-version:
2625
- "^10.0"
@@ -43,14 +42,10 @@ jobs:
4342
exclude:
4443
- php-version: "7.4"
4544
symfony-version: "^6.0"
46-
- php-version: "7.3"
47-
symfony-version: "^6.0"
4845
- php-version: "8.0"
4946
php-code-coverage-version: "^10.0"
5047
- php-version: "7.4"
5148
php-code-coverage-version: "^10.0"
52-
- php-version: "7.3"
53-
php-code-coverage-version: "^10.0"
5449

5550
steps:
5651
- uses: actions/checkout@v4

composer.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
}
1313
],
1414
"require": {
15-
"php": "^7.3 || ^8.0",
15+
"php": "^7.4 || ^8.0",
1616
"composer-runtime-api": "^2.0",
1717
"behat/behat": "^3.10",
1818
"composer/semver": "^3.0",

src/Controller/Cli/CodeCoverageController.php

-4
Original file line numberDiff line numberDiff line change
@@ -14,16 +14,12 @@
1414

1515
class CodeCoverageController implements Controller
1616
{
17-
/**
18-
* {@inheritdoc}
19-
*/
2017
public function configure(Command $command): void
2118
{
2219
$command->addOption('no-coverage', null, InputOption::VALUE_NONE, 'Skip Code Coverage generation');
2320
}
2421

2522
/**
26-
* {@inheritdoc}
2723
* @codeCoverageIgnore
2824
*/
2925
public function execute(InputInterface $input, OutputInterface $output): void

src/Extension.php

-15
Original file line numberDiff line numberDiff line change
@@ -37,16 +37,10 @@
3737

3838
class Extension implements ExtensionInterface
3939
{
40-
/**
41-
* {@inheritdoc}
42-
*/
4340
public function initialize(ExtensionManager $extensionManager): void
4441
{
4542
}
4643

47-
/**
48-
* {@inheritdoc}
49-
*/
5044
public function load(ContainerBuilder $container, array $config): void
5145
{
5246
$container->registerForAutoconfiguration(Controller::class)->addTag(CliExtension::CONTROLLER_TAG);
@@ -61,9 +55,6 @@ public function load(ContainerBuilder $container, array $config): void
6155
$container->setParameter('behat.code_coverage.config.cache', $config['cache']);
6256
}
6357

64-
/**
65-
* {@inheritdoc}
66-
*/
6758
public function configure(ArrayNodeDefinition $builder): void
6859
{
6960
$builder
@@ -185,17 +176,11 @@ public function configure(ArrayNodeDefinition $builder): void
185176
->end();
186177
}
187178

188-
/**
189-
* {@inheritdoc}
190-
*/
191179
public function getConfigKey()
192180
{
193181
return 'code_coverage';
194182
}
195183

196-
/**
197-
* {@inheritdoc}
198-
*/
199184
public function process(ContainerBuilder $container): void
200185
{
201186
/** @var InputInterface $input */

src/Service/ReportService.php

+1-4
Original file line numberDiff line numberDiff line change
@@ -24,10 +24,7 @@
2424

2525
class ReportService
2626
{
27-
/**
28-
* @var array
29-
*/
30-
private $config;
27+
private array $config;
3128

3229
/**
3330
* Constructor.

src/Subscriber/EventSubscriber.php

+3-9
Original file line numberDiff line numberDiff line change
@@ -15,17 +15,11 @@
1515

1616
class EventSubscriber implements EventSubscriberInterface
1717
{
18-
/**
19-
* @var CodeCoverage
20-
*/
21-
private $coverage;
18+
private ?CodeCoverage $coverage;
2219

23-
/**
24-
* @var ReportService
25-
*/
26-
private $reportService;
20+
private ReportService $reportService;
2721

28-
public function __construct(ReportService $reportService, CodeCoverage $coverage = null)
22+
public function __construct(ReportService $reportService, ?CodeCoverage $coverage)
2923
{
3024
$this->reportService = $reportService;
3125
$this->coverage = $coverage;

tests/EventSubscriberTest.php

+4-4
Original file line numberDiff line numberDiff line change
@@ -27,7 +27,7 @@ class EventSubscriberTest extends TestCase
2727
{
2828
public function testCanSubscribeToEvents(): void
2929
{
30-
$eventSubscriber = new EventSubscriber(new ReportService([]));
30+
$eventSubscriber = new EventSubscriber(new ReportService([]), null);
3131
$dispatcher = new EventDispatcher();
3232
$dispatcher->addSubscriber($eventSubscriber);
3333

@@ -40,7 +40,7 @@ public function testBeforeScenarioWithNoCoverage(): void
4040
{
4141
$event = $this->createMock(ScenarioTested::class);
4242

43-
$subscriber = new EventSubscriber(new ReportService([]));
43+
$subscriber = new EventSubscriber(new ReportService([]), null);
4444
$subscriber->beforeScenario($event);
4545

4646
self::assertTrue(true);
@@ -50,7 +50,7 @@ public function testAfterScenarioWithNoCoverage(): void
5050
{
5151
$event = $this->createMock(ScenarioTested::class);
5252

53-
$subscriber = new EventSubscriber(new ReportService([]));
53+
$subscriber = new EventSubscriber(new ReportService([]), null);
5454
$subscriber->afterScenario($event);
5555

5656
self::assertTrue(true);
@@ -60,7 +60,7 @@ public function testAfterExerciseWithNoCoverage(): void
6060
{
6161
$event = $this->createMock(ExerciseCompleted::class);
6262

63-
$subscriber = new EventSubscriber(new ReportService([]));
63+
$subscriber = new EventSubscriber(new ReportService([]), null);
6464
$subscriber->afterExercise($event);
6565

6666
self::assertTrue(true);

0 commit comments

Comments
 (0)