Skip to content

Commit

Permalink
Modfied ShibbolethTest to use the entity interface
Browse files Browse the repository at this point in the history
  • Loading branch information
padmasreegade authored and demiankatz committed Jan 29, 2025
1 parent 6b1ac1e commit b38beb9
Showing 1 changed file with 8 additions and 8 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -311,8 +311,8 @@ public function testSessionInitiator(): void
public function testLogin(): void
{
$user = $this->getAuthObject()->authenticate($this->getLoginRequest());
$this->assertEquals('testuser', $user->username);
$this->assertEquals('[email protected]', $user->email);
$this->assertEquals('testuser', $user->getUsername());
$this->assertEquals('[email protected]', $user->getEmail());
}

/**
Expand All @@ -324,8 +324,8 @@ public function testLogin1(): void
{
$user = $this->getAuthObject(null, $this->getShibbolethConfig())
->authenticate($this->getLoginRequest($this->user1, false));
$this->assertEquals($user->cat_username, 'example1.testuser1');
$this->assertEquals($user->username, 'testuser1');
$this->assertEquals($user->getCatUsername(), 'example1.testuser1');
$this->assertEquals($user->getUsername(), 'testuser1');
}

/**
Expand All @@ -337,8 +337,8 @@ public function testLogin2(): void
{
$user = $this->getAuthObject(null, $this->getShibbolethConfig())
->authenticate($this->getLoginRequest($this->user2, false));
$this->assertEquals($user->cat_username, 'example2.12345');
$this->assertEquals($user->username, 'testuser2');
$this->assertEquals($user->getCatUsername(), 'example2.12345');
$this->assertEquals($user->getUsername(), 'testuser2');
}

/**
Expand All @@ -362,8 +362,8 @@ public function testProxyLogin(): void
{
$user = $this->getAuthObject(null, $this->getShibbolethConfig(), true, false)
->authenticate($this->getLoginRequest($this->proxyUser, true));
$this->assertEquals($user->cat_username, 'example1.testuser3');
$this->assertEquals($user->username, 'testuser3');
$this->assertEquals($user->getCatUsername(), 'example1.testuser3');
$this->assertEquals($user->getUsername(), 'testuser3');
}

/**
Expand Down

0 comments on commit b38beb9

Please sign in to comment.