-
-
Notifications
You must be signed in to change notification settings - Fork 340
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Assert JoinColumns in CPP should be converted (#2991)
Co-authored-by: Grégoire Paris <postmaster@greg0ire.fr>
- Loading branch information
1 parent
f4f758c
commit ee222b2
Showing
8 changed files
with
70 additions
and
7 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
41 changes: 41 additions & 0 deletions
41
...nnotationToAttributeRector/Fixture/doctrine_nested_join_columns_promoted_property.php.inc
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,41 @@ | ||
<?php | ||
|
||
namespace Rector\Tests\Php80\Rector\Property\NestedAnnotationToAttributeRector\Fixture; | ||
|
||
use Doctrine\ORM\Mapping\JoinColumn; | ||
use Doctrine\ORM\Mapping\JoinColumns; | ||
|
||
final class DoctrineNestedJoinColumnsPromotedProperty | ||
{ | ||
public function __construct( | ||
/** | ||
* @JoinColumns({ | ||
* @JoinColumn(name="entity_id", referencedColumnName="id"), | ||
* @JoinColumn(name="entity_type", referencedColumnName="entity_type"), | ||
* }) | ||
*/ | ||
protected $page, | ||
) { | ||
} | ||
} | ||
|
||
?> | ||
----- | ||
<?php | ||
|
||
namespace Rector\Tests\Php80\Rector\Property\NestedAnnotationToAttributeRector\Fixture; | ||
|
||
use Doctrine\ORM\Mapping\JoinColumn; | ||
use Doctrine\ORM\Mapping\JoinColumns; | ||
|
||
final class DoctrineNestedJoinColumnsPromotedProperty | ||
{ | ||
public function __construct( | ||
#[JoinColumn(name: 'entity_id', referencedColumnName: 'id')] | ||
#[JoinColumn(name: 'entity_type', referencedColumnName: 'entity_type')] | ||
protected $page, | ||
) { | ||
} | ||
} | ||
|
||
?> |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters