Returned values may either be a string (when the Trait is not in this project) or a TraitDescriptor.
public getUsedTraits ( ) : phpDocumentor\Descriptor\Collection | ||
Результат | phpDocumentor\Descriptor\Collection |
/** * @covers phpDocumentor\Descriptor\TraitDescriptor::getUsedTraits * @covers phpDocumentor\Descriptor\TraitDescriptor::setUsedTraits */ public function testSettingAndGettingUsedTraits() { $this->assertInstanceOf('phpDocumentor\\Descriptor\\Collection', $this->fixture->getUsedTraits()); $usedTraitsCollection = new Collection(); $this->fixture->setUsedTraits($usedTraitsCollection); $this->assertSame($usedTraitsCollection, $this->fixture->getUsedTraits()); }