/** * @test * @group Authentication * @group Attributes */ public function epti_attribute_is_correctly_set_when_creating_an_authenticated_user() { $expectedAttributeSet = AttributeSet::create([new Attribute(new AttributeDefinition('eduPersonTargetedID', 'urn:mace:dir:attribute-def:eduPersonTargetedID'), ['abcd-some-value-xyz']), new Attribute(new AttributeDefinition('displayName', 'urn:mace:dir:attribute-def:displayName'), ['Tester'])]); $assertionWithEpti = $this->getAssertionWithEpti(); $attributeDictionary = $this->getAttributeDictionary(); $assertionAdapter = $this->mockAssertionAdapterWith(AttributeSet::createFrom($assertionWithEpti, $attributeDictionary), 'abcd-some-value-xyz'); $authenticatedUser = AuthenticatedUser::createFrom($assertionAdapter, []); $actualAttributeSet = $authenticatedUser->getAttributes(); $this->assertEquals($expectedAttributeSet, $actualAttributeSet); }