Skip to content

Commit b7f51a9

Browse files
greg0ireostrolucky
authored andcommitted
Change overlooked paths in phpcs.xml.dist
It seems that while modernizing the directory structure, I overlooked some of the paths present in that configuration file.
1 parent dc6c94d commit b7f51a9

File tree

3 files changed

+11
-8
lines changed

3 files changed

+11
-8
lines changed

phpcs.xml.dist

Lines changed: 5 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -12,6 +12,7 @@
1212
<config name="php_version" value="70400"/>
1313

1414
<file>src</file>
15+
<file>tests</file>
1516

1617
<rule ref="Doctrine">
1718
<exclude name="SlevomatCodingStandard.TypeHints.DeclareStrictTypes"/>
@@ -22,11 +23,11 @@
2223
</rule>
2324

2425
<rule ref="PSR1.Classes.ClassDeclaration.MultipleClasses">
25-
<exclude-pattern>Tests/*</exclude-pattern>
26-
<exclude-pattern>Repository/RepositoryFactoryCompatibility.php</exclude-pattern>
27-
<exclude-pattern>Repository/ServiceEntityRepository.php</exclude-pattern>
26+
<exclude-pattern>tests/*</exclude-pattern>
27+
<exclude-pattern>src/Repository/RepositoryFactoryCompatibility.php</exclude-pattern>
28+
<exclude-pattern>src/Repository/ServiceEntityRepository.php</exclude-pattern>
2829
</rule>
2930
<rule ref="Squiz.Classes.ClassFileName.NoMatch">
30-
<exclude-pattern>Tests/*</exclude-pattern>
31+
<exclude-pattern>tests/*</exclude-pattern>
3132
</rule>
3233
</ruleset>

tests/DependencyInjection/AbstractDoctrineExtensionTest.php

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -240,7 +240,7 @@ public function testDbalLoadSinglePrimaryReplicaConnection(): void
240240

241241
public function testDbalLoadSavepointsForNestedTransactions(): void
242242
{
243-
if (!method_exists(Connection::class, 'getEventManager')) {
243+
if (! method_exists(Connection::class, 'getEventManager')) {
244244
self::markTestSkipped('This test requires DBAL < 4');
245245
}
246246

tests/DependencyInjection/DoctrineExtensionTest.php

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -558,10 +558,12 @@ public function testUseSavePointsAddMethodCallToAddSavepointsToTheConnection():
558558

559559
$calls = $container->getDefinition('doctrine.dbal.default_connection')->getMethodCalls();
560560
$this->assertCount((int) $isUsingDBAL3, $calls);
561-
if ($isUsingDBAL3) {
562-
$this->assertEquals('setNestTransactionsWithSavepoints', $calls[0][0]);
563-
$this->assertTrue($calls[0][1][0]);
561+
if (! $isUsingDBAL3) {
562+
return;
564563
}
564+
565+
$this->assertEquals('setNestTransactionsWithSavepoints', $calls[0][0]);
566+
$this->assertTrue($calls[0][1][0]);
565567
}
566568

567569
public function testAutoGenerateProxyClasses(): void

0 commit comments

Comments
 (0)