TraitUseTest
extends TestCase
in package
FinalYes
Base test case for all strategies, to be sure that they check if the can handle objects before handeling them.
Attributes
- #[CoversClass]
- \phpDocumentor\Reflection\Php\Factory\TraitUse::class
- #[CoversClass]
- \phpDocumentor\Reflection\Php\Factory\AbstractFactory::class
Table of Contents
Properties
Methods
- consumerProvider() : array<string|int, array<string|int, mixed>>
- createContext() : ContextStack
- testCreateThrowsException() : void
- testCreateThrowsExceptionWhenStackDoesNotContainClass() : void
- testCreateWillAddUsedTraitToContextTop() : void
- testMatchesOnlyTraitUseNode() : void
- setUp() : void
- givenTraitUse() : TraitUse
Properties
$fixture
protected
ProjectFactoryStrategy
$fixture
Methods
consumerProvider()
public
static consumerProvider() : array<string|int, array<string|int, mixed>>
Return values
array<string|int, array<string|int, mixed>>createContext()
public
static createContext([Context|null $typeContext = null ]) : ContextStack
Parameters
- $typeContext : Context|null = null
Return values
ContextStacktestCreateThrowsException()
public
testCreateThrowsException() : void
testCreateThrowsExceptionWhenStackDoesNotContainClass()
public
testCreateThrowsExceptionWhenStackDoesNotContainClass() : void
testCreateWillAddUsedTraitToContextTop()
public
testCreateWillAddUsedTraitToContextTop(Class_|Trait_ $traitConsumer) : void
Parameters
Attributes
- #[DataProvider]
- 'consumerProvider'
testMatchesOnlyTraitUseNode()
public
testMatchesOnlyTraitUseNode() : void
setUp()
protected
setUp() : void
givenTraitUse()
private
givenTraitUse() : TraitUse