Skip to content

Commit

Permalink
PUB-2681 - Updated integration tests
Browse files Browse the repository at this point in the history
  • Loading branch information
ChrisS1512 committed Dec 5, 2024
1 parent aecbd63 commit 180b67b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -610,6 +610,7 @@ void testDeleteAccountNotFound() throws Exception {
}

@Test
@Sql(executionPhase = Sql.ExecutionPhase.BEFORE_TEST_METHOD, scripts = "classpath:add-admin-users.sql")
void testV2SystemAdminDeletesVerifiedUser() throws Exception {
validUser.setUserProvenance(UserProvenances.CFT_IDAM);
validUser.setRoles(Roles.VERIFIED);
Expand Down Expand Up @@ -675,6 +676,7 @@ void testV2SystemAdminDeletesThirdPartyUser() throws Exception {
}

@Test
@Sql(executionPhase = Sql.ExecutionPhase.BEFORE_TEST_METHOD, scripts = "classpath:add-admin-users.sql")
void testV2SystemAdminDeletesSuperAdminUser() throws Exception {
superAdminUser.setUserProvenance(UserProvenances.CFT_IDAM);
String superAdminUserId = getSuperAdminUserId(superAdminUser);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@

import java.util.ArrayList;
import java.util.List;
import java.util.UUID;

import static org.junit.jupiter.api.Assertions.assertEquals;
import static org.mockito.ArgumentMatchers.any;
Expand Down Expand Up @@ -223,7 +224,7 @@ void testUnauthorizedCreateSystemAdminAccount() throws Exception {
MockMvcRequestBuilders
.post(CREATE_SYSTEM_ADMIN_URL)
.content(OBJECT_MAPPER.writeValueAsString(systemAdmin))
.header(ISSUER_HEADER, ISSUER_ID)
.header(ISSUER_HEADER, UUID.randomUUID().toString())
.contentType(MediaType.APPLICATION_JSON);

MvcResult responseCreateSystemAdminUser = mockMvc.perform(createRequest)
Expand Down

0 comments on commit 180b67b

Please sign in to comment.