Skip to content

Commit

Permalink
add test fixture for rectorphp/rector#6928
Browse files Browse the repository at this point in the history
  • Loading branch information
TomasVotruba committed Jan 11, 2022
1 parent e27e483 commit 56f80d2
Show file tree
Hide file tree
Showing 2 changed files with 43 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,33 @@
<?php

namespace Rector\Tests\Php80\Rector\Class_\AnnotationToAttributeRector\Fixture;

use Rector\Tests\Php80\Rector\Class_\AnnotationToAttributeRector\Source\GenericAnnotation;
use Rector\Tests\Php80\Rector\Class_\AnnotationToAttributeRector\Source\ConstantReference;

/**
* @GenericAnnotation(
* properties={
* ConstantReference::FIRST_NAME = "John",
* }
* )
*/
final class NestedArray
{
}

?>
-----
<?php

namespace Rector\Tests\Php80\Rector\Class_\AnnotationToAttributeRector\Fixture;

use Rector\Tests\Php80\Rector\Class_\AnnotationToAttributeRector\Source\GenericAnnotation;
use Rector\Tests\Php80\Rector\Class_\AnnotationToAttributeRector\Source\ConstantReference;

#[GenericAnnotation(properties: [ConstantReference::FIRST_NAME => 'John'])]
final class NestedArray
{
}

?>
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
<?php

declare(strict_types=1);

namespace Rector\Tests\Php80\Rector\Class_\AnnotationToAttributeRector\Source;

final class ConstantReference
{
public const FIRST_NAME = 'firstName';
}

0 comments on commit 56f80d2

Please sign in to comment.