-
-
Notifications
You must be signed in to change notification settings - Fork 313
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
#1 Use statements are taken into account for class resolution
- Loading branch information
Showing
7 changed files
with
217 additions
and
13 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
40 changes: 40 additions & 0 deletions
40
tests/IntegrationTests/DI/Fixtures/BeanInjectionTest/Issue1.php
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,40 @@ | ||
<?php | ||
/** | ||
* PHP-DI | ||
* | ||
* @link http://mnapoli.github.com/PHP-DI/ | ||
* @copyright 2012 Matthieu Napoli (http://mnapoli.fr/) | ||
* @license http://www.opensource.org/licenses/mit-license.php MIT (see the LICENSE file) | ||
*/ | ||
|
||
namespace IntegrationTests\DI\Fixtures\BeanInjectionTest; | ||
|
||
use \DI\Annotations\Inject; | ||
use \IntegrationTests\DI\Fixtures\BeanInjectionTest\Class2; | ||
use \IntegrationTests\DI\Fixtures\BeanInjectionTest\Class2 as Alias; | ||
use \IntegrationTests\DI\Fixtures\BeanInjectionTest as NamespaceAlias; | ||
|
||
/** | ||
* Fixture class | ||
*/ | ||
class Issue1 { | ||
|
||
/** | ||
* @Inject | ||
* @var Class2 | ||
*/ | ||
public $class2; | ||
|
||
/** | ||
* @Inject | ||
* @var Alias | ||
*/ | ||
public $alias; | ||
|
||
/** | ||
* @Inject | ||
* @var NamespaceAlias\Class2 | ||
*/ | ||
public $namespaceAlias; | ||
|
||
} |
32 changes: 32 additions & 0 deletions
32
tests/IntegrationTests/DI/Fixtures/BeanInjectionTest/Issue1/AnotherIssue1.php
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,32 @@ | ||
<?php | ||
/** | ||
* PHP-DI | ||
* | ||
* @link http://mnapoli.github.com/PHP-DI/ | ||
* @copyright 2012 Matthieu Napoli (http://mnapoli.fr/) | ||
* @license http://www.opensource.org/licenses/mit-license.php MIT (see the LICENSE file) | ||
*/ | ||
|
||
namespace IntegrationTests\DI\Fixtures\BeanInjectionTest\Issue1; | ||
|
||
use \DI\Annotations\Inject; | ||
use \IntegrationTests\DI\Fixtures\BeanInjectionTest\Class2; | ||
|
||
/** | ||
* Fixture class | ||
*/ | ||
class AnotherIssue1 { | ||
|
||
/** | ||
* @Inject | ||
* @var Class2 | ||
*/ | ||
public $dependency; | ||
|
||
/** | ||
* @Inject | ||
* @var Dependency | ||
*/ | ||
public $sameNamespaceDependency; | ||
|
||
} |
17 changes: 17 additions & 0 deletions
17
tests/IntegrationTests/DI/Fixtures/BeanInjectionTest/Issue1/Dependency.php
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,17 @@ | ||
<?php | ||
/** | ||
* PHP-DI | ||
* | ||
* @link http://mnapoli.github.com/PHP-DI/ | ||
* @copyright 2012 Matthieu Napoli (http://mnapoli.fr/) | ||
* @license http://www.opensource.org/licenses/mit-license.php MIT (see the LICENSE file) | ||
*/ | ||
|
||
namespace IntegrationTests\DI\Fixtures\BeanInjectionTest\Issue1; | ||
|
||
/** | ||
* Fixture class | ||
*/ | ||
class Dependency { | ||
|
||
} |
25 changes: 25 additions & 0 deletions
25
tests/IntegrationTests/DI/Fixtures/BeanInjectionTest/NotFoundVarAnnotation.php
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,25 @@ | ||
<?php | ||
/** | ||
* PHP-DI | ||
* | ||
* @link http://mnapoli.github.com/PHP-DI/ | ||
* @copyright 2012 Matthieu Napoli (http://mnapoli.fr/) | ||
* @license http://www.opensource.org/licenses/mit-license.php MIT (see the LICENSE file) | ||
*/ | ||
|
||
namespace IntegrationTests\DI\Fixtures\BeanInjectionTest; | ||
|
||
use \DI\Annotations\Inject; | ||
|
||
/** | ||
* Fixture class | ||
*/ | ||
class NotFoundVarAnnotation { | ||
|
||
/** | ||
* @Inject | ||
* @var this_is_a_non_existent_class | ||
*/ | ||
public $class2; | ||
|
||
} |