Skip to content

Commit

Permalink
Move Attribute to shorter Namespace
Browse files Browse the repository at this point in the history
→ \Ebln\Attrib\ForceFactory
  • Loading branch information
ebln committed Jun 7, 2024
1 parent 79ebd45 commit fd53d3f
Show file tree
Hide file tree
Showing 10 changed files with 10 additions and 8 deletions.
2 changes: 1 addition & 1 deletion src/ForceFactory.php → attrib/ForceFactory.php
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

declare(strict_types=1);

namespace Ebln\PHPStan\EnforceFactory;
namespace Ebln\Attrib;

/**
* Marks classes to be instanciated by certain factories
Expand Down
1 change: 1 addition & 0 deletions composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -23,6 +23,7 @@
},
"autoload": {
"psr-4": {
"Ebln\\Attrib\\": "attrib/",
"Ebln\\PHPStan\\EnforceFactory\\": "src/"
}
},
Expand Down
1 change: 1 addition & 0 deletions src/ForceFactoryRule.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@

namespace Ebln\PHPStan\EnforceFactory;

use Ebln\Attrib\ForceFactory;
use PhpParser\Node;
use PHPStan\Analyser\Scope;
use PHPStan\Reflection\ReflectionProvider;
Expand Down
2 changes: 1 addition & 1 deletion tests/dataAttrib/code/EmptyProduct.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

namespace Test\Ebln\PHPStan\EnforceFactory\dataAttrib\code;

use Ebln\PHPStan\EnforceFactory\ForceFactory;
use Ebln\Attrib\ForceFactory;

#[ForceFactory()]
class EmptyProduct
Expand Down
2 changes: 1 addition & 1 deletion tests/dataAttrib/code/ForcedFactoryProduct.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

namespace Test\Ebln\PHPStan\EnforceFactory\dataAttrib\code;

use Ebln\PHPStan\EnforceFactory\ForceFactory;
use Ebln\Attrib\ForceFactory;
use Test\Ebln\PHPStan\EnforceFactory\dataAttrib\ForcedFactory;
use Test\Ebln\PHPStan\EnforceFactory\dataAttrib\TraitFactory;

Expand Down
2 changes: 1 addition & 1 deletion tests/dataAttrib/code/IndependentForcedFactoryProduct.php
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@

use Test\Ebln\PHPStan\EnforceFactory\dataAttrib\IndependentFactory;

#[\Ebln\PHPStan\EnforceFactory\ForceFactory(IndependentFactory::class)]
#[\Ebln\Attrib\ForceFactory(IndependentFactory::class)]
#[\INVALID\NOT\FOUND\ATTRIBUTE(IndependentFactory::class)]
class IndependentForcedFactoryProduct
{
Expand Down
2 changes: 1 addition & 1 deletion tests/dataAttrib/code/LoopholeProduct.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

namespace Test\Ebln\PHPStan\EnforceFactory\dataAttrib\code;

use Ebln\PHPStan\EnforceFactory\ForceFactory;
use Ebln\Attrib\ForceFactory;
use Test\Ebln\PHPStan\EnforceFactory\dataAttrib\ForcedFactory;
use Test\Ebln\PHPStan\EnforceFactory\dataAttrib\TraitFactory;

Expand Down
2 changes: 1 addition & 1 deletion tests/dataMixed/code/AttributeProduct.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

namespace Test\Ebln\PHPStan\EnforceFactory\dataMixed\code;

use Ebln\PHPStan\EnforceFactory\ForceFactory;
use Ebln\Attrib\ForceFactory;
use Test\Ebln\PHPStan\EnforceFactory\dataMixed\AttributeFactory;

#[ForceFactory(AttributeFactory::class)]
Expand Down
2 changes: 1 addition & 1 deletion tests/dataMixed/code/MismatchedProduct.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

namespace Test\Ebln\PHPStan\EnforceFactory\dataMixed\code;

use Ebln\PHPStan\EnforceFactory\ForceFactory;
use Ebln\Attrib\ForceFactory;
use Ebln\PHPStan\EnforceFactory\ForceFactoryInterface;
use Test\Ebln\PHPStan\EnforceFactory\dataMixed\AttributeFactory;
use Test\Ebln\PHPStan\EnforceFactory\dataMixed\ForcedFactory;
Expand Down
2 changes: 1 addition & 1 deletion tests/dataMixed/code/MixedProduct.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@

namespace Test\Ebln\PHPStan\EnforceFactory\dataMixed\code;

use Ebln\PHPStan\EnforceFactory\ForceFactory;
use Ebln\Attrib\ForceFactory;
use Ebln\PHPStan\EnforceFactory\ForceFactoryInterface;
use Test\Ebln\PHPStan\EnforceFactory\dataMixed\AttributeFactory;
use Test\Ebln\PHPStan\EnforceFactory\dataMixed\ForcedFactory;
Expand Down

0 comments on commit fd53d3f

Please sign in to comment.