fix namespace

This commit is contained in:
TomasVotruba 2020-02-14 23:48:53 +01:00
parent 025bb364f4
commit 1c273c902c
25 changed files with 49 additions and 46 deletions

View File

@ -21,6 +21,9 @@ use Rector\Core\RectorDefinition\RectorDefinition;
use Rector\NodeTypeResolver\Node\AttributeKey;
use Rector\PHPStan\Type\ShortenedObjectType;
/**
* @see \Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\AnnotateThrowablesRectorTest
*/
final class AnnotateThrowablesRector extends AbstractRector
{
/**

View File

@ -1,6 +1,6 @@
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
/**
* @throws \Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Source\TheException
@ -14,7 +14,7 @@ function throwCustomExceptionAlreadyAnnotatedInFunction()
-----
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
/**
* @throws \Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Source\TheException

View File

@ -1,6 +1,6 @@
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
class CustomExceptionAlreadyAnnotatedInMethod
{
@ -14,7 +14,7 @@ class CustomExceptionAlreadyAnnotatedInMethod
-----
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
class CustomExceptionAlreadyAnnotatedInMethod
{

View File

@ -1,6 +1,6 @@
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
/**
* This is a comment.
@ -16,7 +16,7 @@ function throwCustomExceptionInFunctionWithDockblock(int $code)
-----
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
/**
* This is a comment.

View File

@ -1,6 +1,6 @@
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
function throwCustomExceptionInFunctionWithoutDockblock()
{
@ -11,7 +11,7 @@ function throwCustomExceptionInFunctionWithoutDockblock()
-----
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
/**
* @throws \Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Source\TheException

View File

@ -1,6 +1,6 @@
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
class CustomExceptionInMethodWithDocblock
{
@ -19,7 +19,7 @@ class CustomExceptionInMethodWithDocblock
-----
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
class CustomExceptionInMethodWithDocblock
{

View File

@ -1,6 +1,6 @@
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
class CustomExceptionInMethodWithoutDocblock
{
@ -14,7 +14,7 @@ class CustomExceptionInMethodWithoutDocblock
-----
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
class CustomExceptionInMethodWithoutDocblock
{

View File

@ -1,6 +1,6 @@
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
/**
* @throws \Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Source\TheException
@ -19,7 +19,7 @@ function throwCustomExceptionThrownInTwoFunctionsSecond()
-----
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
/**
* @throws \Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Source\TheException

View File

@ -1,6 +1,6 @@
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
class CustomExceptionThrownInTwoMethods
{
@ -22,7 +22,7 @@ class CustomExceptionThrownInTwoMethods
-----
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
class CustomExceptionThrownInTwoMethods
{

View File

@ -1,6 +1,6 @@
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
/**
* @throws \RuntimeException
@ -14,7 +14,7 @@ function throwRootExceptionAlreadyAnnotatedInFunction()
-----
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
/**
* @throws \RuntimeException

View File

@ -1,6 +1,6 @@
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
class RootExceptionAlreadyAnnotatedInMethod
{
@ -17,7 +17,7 @@ class RootExceptionAlreadyAnnotatedInMethod
-----
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
class RootExceptionAlreadyAnnotatedInMethod
{

View File

@ -1,6 +1,6 @@
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
/**
* This is a comment.
@ -16,7 +16,7 @@ function throwRootExceptionInFunctionWithDocblock(int $code)
-----
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
/**
* This is a comment.

View File

@ -1,6 +1,6 @@
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
function throwRootExceptionInFunctionWithoutDocblock()
{
@ -11,7 +11,7 @@ function throwRootExceptionInFunctionWithoutDocblock()
-----
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
/**
* @throws \RuntimeException

View File

@ -1,6 +1,6 @@
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
class RootExceptionInMethodWithDocblock
{
@ -19,7 +19,7 @@ class RootExceptionInMethodWithDocblock
-----
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
class RootExceptionInMethodWithDocblock
{

View File

@ -1,6 +1,6 @@
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
class RootExceptionInMethodWithoutDocblock
{
@ -14,7 +14,7 @@ class RootExceptionInMethodWithoutDocblock
-----
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
class RootExceptionInMethodWithoutDocblock
{

View File

@ -1,6 +1,6 @@
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
/**
* @throws \RuntimeException
@ -19,7 +19,7 @@ function throwRootExceptionThrownInTwoFunctionsSecond()
-----
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
/**
* @throws \RuntimeException

View File

@ -1,6 +1,6 @@
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
class RootExceptionThrownInTwoMethods
{
@ -22,7 +22,7 @@ class RootExceptionThrownInTwoMethods
-----
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
class RootExceptionThrownInTwoMethods
{

View File

@ -1,6 +1,6 @@
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
use \RuntimeException;
@ -16,7 +16,7 @@ function throwRootImportedExceptionAlreadyAnnotatedInFunction()
-----
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
use \RuntimeException;

View File

@ -1,6 +1,6 @@
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
use \RuntimeException;
@ -19,7 +19,7 @@ class RootImportedExceptionAlreadyAnnotatedInMethod
-----
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
use \RuntimeException;

View File

@ -1,6 +1,6 @@
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
use Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Source\TheException;

View File

@ -1,6 +1,6 @@
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
use Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Source\TheException;

View File

@ -1,6 +1,6 @@
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
use Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Source\TheException;
use Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Source\TheExceptionTheSecond;
@ -23,7 +23,7 @@ function throwWithFactoryMethodNoReturnTypeHinting()
-----
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
use Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Source\TheException;
use Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Source\TheExceptionTheSecond;

View File

@ -1,6 +1,6 @@
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
use Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Source\TheException;
use Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Source\TheExceptionTheSecond;
@ -33,7 +33,7 @@ function throwWithFactoryMethodNotAnnotated()
-----
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
use Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Source\TheException;
use Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Source\TheExceptionTheSecond;

View File

@ -1,6 +1,6 @@
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
use Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Source\TheException;
use Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Source\TheExceptionTheSecond;
@ -32,7 +32,7 @@ function throwWithFactoryStaticMethodNotAnnotated()
-----
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
use Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Source\TheException;
use Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Source\TheExceptionTheSecond;

View File

@ -1,6 +1,6 @@
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
use Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Source\TheException;
use Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Source\TheExceptionTheSecond;
@ -37,7 +37,7 @@ function throwWithFactoryStaticMethodWithReturnDockblock()
-----
<?php
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowables\Fixture;
namespace Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Fixture;
use Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Source\TheException;
use Rector\CodingStyle\Tests\Rector\Throw_\AnnotateThrowablesRector\Source\TheExceptionTheSecond;