Skip to content

Commit

Permalink
Fix: Adjust Methods\FinalInAbstractClassRule to ignore Doctrine entities
Browse files Browse the repository at this point in the history
  • Loading branch information
localheinz committed Dec 1, 2024
1 parent 449466b commit c873637
Show file tree
Hide file tree
Showing 21 changed files with 372 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<?php

declare(strict_types=1);

namespace Ergebnis\PHPStan\Rules\Test\Fixture\Methods\FinalInAbstractClassRule\Failure;

/** @eNtItY */
abstract class AbstractClassWithProtectedMethodAndWithoutEntityAnnotationInInlineDocBlock
{
protected function method(): void
{
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<?php

declare(strict_types=1);

namespace Ergebnis\PHPStan\Rules\Test\Fixture\Methods\FinalInAbstractClassRule\Failure;

/**
* @eNtItY
*/
abstract class AbstractClassWithProtectedMethodAndWithoutEntityAnnotationInMultilineDocBlock
{
protected function method(): void
{
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<?php

declare(strict_types=1);

namespace Ergebnis\PHPStan\Rules\Test\Fixture\Methods\FinalInAbstractClassRule\Failure;

/** @OrM\eNtItY */
abstract class AbstractClassWithProtectedMethodAndWithoutOrmEntityAnnotationInInlineDocBlock
{
protected function method(): void
{
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<?php

declare(strict_types=1);

namespace Ergebnis\PHPStan\Rules\Test\Fixture\Methods\FinalInAbstractClassRule\Failure;

/**
* @OrM\eNtItY
*/
abstract class AbstractClassWithProtectedMethodAndWithoutOrmEntityAnnotationInMultilineDocBlock
{
protected function method(): void
{
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<?php

declare(strict_types=1);

namespace Ergebnis\PHPStan\Rules\Test\Fixture\Methods\FinalInAbstractClassRule\Failure;

/** @eNtItY */
abstract class AbstractClassWithPublicMethodAndWithoutEntityAnnotationInInlineDocBlock
{
public function method(): void
{
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<?php

declare(strict_types=1);

namespace Ergebnis\PHPStan\Rules\Test\Fixture\Methods\FinalInAbstractClassRule\Failure;

/**
* @eNtItY
*/
abstract class AbstractClassWithPublicMethodAndWithoutEntityAnnotationInMultilineDocBlock
{
public function method(): void
{
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<?php

declare(strict_types=1);

namespace Ergebnis\PHPStan\Rules\Test\Fixture\Methods\FinalInAbstractClassRule\Failure;

/** @OrM\eNtItY */
abstract class AbstractClassWithPublicMethodAndWithoutOrmEntityAnnotationInInlineDocBlock
{
public function method(): void
{
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<?php

declare(strict_types=1);

namespace Ergebnis\PHPStan\Rules\Test\Fixture\Methods\FinalInAbstractClassRule\Failure;

/**
* @OrM\eNtItY
*/
abstract class AbstractClassWithPublicMethodAndWithoutOrmEntityAnnotationInMultilineDocBlock
{
public function method(): void
{
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<?php

declare(strict_types=1);

namespace Ergebnis\PHPStan\Rules\Test\Fixture\Methods\FinalInAbstractClassRule\Success;

/** @Entity */
abstract class AbstractClassWithProtectedMethodAndEntityAnnotationInInlineDocBlock
{
protected function method(): void
{
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<?php

declare(strict_types=1);

namespace Ergebnis\PHPStan\Rules\Test\Fixture\Methods\FinalInAbstractClassRule\Success;

/**
* @Entity
*/
abstract class AbstractClassWithProtectedMethodAndEntityAnnotationInMultilineDocBlock
{
protected function method(): void
{
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<?php

declare(strict_types=1);

namespace Ergebnis\PHPStan\Rules\Test\Fixture\Methods\FinalInAbstractClassRule\Success;

/** @ORM\Entity */
abstract class AbstractClassWithProtectedMethodAndOrmEntityAnnotationInInlineDocBlock
{
protected function method(): void
{
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<?php

declare(strict_types=1);

namespace Ergebnis\PHPStan\Rules\Test\Fixture\Methods\FinalInAbstractClassRule\Success;

/**
* @ORM\Entity
*/
abstract class AbstractClassWithProtectedMethodAndOrmEntityAnnotationInMultilineDocBlock
{
protected function method(): void
{
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<?php

declare(strict_types=1);

namespace Ergebnis\PHPStan\Rules\Test\Fixture\Methods\FinalInAbstractClassRule\Success;

/** @ORM\Mapping\Entity */
abstract class AbstractClassWithProtectedMethodAndOrmMappingEntityAnnotationInInlineDocBlock
{
protected function method(): void
{
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<?php

declare(strict_types=1);

namespace Ergebnis\PHPStan\Rules\Test\Fixture\Methods\FinalInAbstractClassRule\Success;

/**
* @ORM\Mapping\Entity
*/
abstract class AbstractClassWithProtectedMethodAndOrmMappingEntityAnnotationInMultilineDocBlock
{
protected function method(): void
{
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<?php

declare(strict_types=1);

namespace Ergebnis\PHPStan\Rules\Test\Fixture\Methods\FinalInAbstractClassRule\Success;

/** @Entity */
abstract class AbstractClassWithPublicMethodAndEntityAnnotationInInlineDocBlock
{
public function method(): void
{
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<?php

declare(strict_types=1);

namespace Ergebnis\PHPStan\Rules\Test\Fixture\Methods\FinalInAbstractClassRule\Success;

/**
* @Entity
*/
abstract class AbstractClassWithPublicMethodAndEntityAnnotationInMultilineDocBlock
{
public function method(): void
{
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<?php

declare(strict_types=1);

namespace Ergebnis\PHPStan\Rules\Test\Fixture\Methods\FinalInAbstractClassRule\Success;

/** @ORM\Entity */
abstract class AbstractClassWithPublicMethodAndOrmEntityAnnotationInInlineDocBlock
{
public function method(): void
{
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<?php

declare(strict_types=1);

namespace Ergebnis\PHPStan\Rules\Test\Fixture\Methods\FinalInAbstractClassRule\Success;

/**
* @ORM\Entity
*/
abstract class AbstractClassWithPublicMethodAndOrmEntityAnnotationInMultilineDocBlock
{
public function method(): void
{
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
<?php

declare(strict_types=1);

namespace Ergebnis\PHPStan\Rules\Test\Fixture\Methods\FinalInAbstractClassRule\Success;

/** @ORM\Mapping\Entity */
abstract class AbstractClassWithPublicMethodAndOrmMappingEntityAnnotationInInlineDocBlock
{
public function method(): void
{
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
<?php

declare(strict_types=1);

namespace Ergebnis\PHPStan\Rules\Test\Fixture\Methods\FinalInAbstractClassRule\Success;

/**
* @ORM\Mapping\Entity
*/
abstract class AbstractClassWithPublicMethodAndOrmMappingEntityAnnotationInMultilineDocBlock
{
public function method(): void
{
}
}
Loading

0 comments on commit c873637

Please sign in to comment.