Skip to content
Snippets Groups Projects
Commit 3baddfbc authored by Patryk Kazimierowski's avatar Patryk Kazimierowski
Browse files

removed redundant test

parent e5bcebca
No related branches found
No related tags found
2 merge requests!140Itest fixes,!137Draft: Release/1.7.1
Pipeline #93273 passed
...@@ -75,18 +75,6 @@ class OidcUserServiceImplTest { ...@@ -75,18 +75,6 @@ class OidcUserServiceImplTest {
assertEquals(existingUser, result); assertEquals(existingUser, result);
} }
@Test
void shouldThrowExceptionWhenPreferredUsernameDoesNotMatchEmail() {
//given
User existingUser = new User("testuser");
existingUser.setEmail("diffrent@example.com");
//when
when(userService.existsBySamlToken("test-sub")).thenReturn(false);
when(userService.existsBySamlToken("testuser")).thenReturn(true);
when(userService.findBySamlToken("testuser")).thenReturn(Optional.of(existingUser));
//then
assertThrows(ExternalUserMatchException.class, () -> oidcUserService.checkUser(oidcUser));
}
} }
\ No newline at end of file
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment