Package idatt2106.group3.backend.Web
Class ActivityControllerTest
- java.lang.Object
-
- idatt2106.group3.backend.Web.ActivityControllerTest
-
@SpringBootTest @AutoConfigureMockMvc @ExtendWith(org.mockito.junit.jupiter.MockitoExtension.class) @ActiveProfiles("test") public class ActivityControllerTest extends java.lang.Object
-
-
Constructor Summary
Constructors Constructor Description ActivityControllerTest()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description void
addUserToActivity_ExistingUserAdded_StatusCreated()
void
createActivity_PostActivity_StatusCreated()
void
deleteActivity_ShouldDeleteActivity_StatusOk()
void
editActivity_UpdateActivity_StatusOk()
void
getActivities_ReturnListAndStatus_StatusOk()
void
getActivity_ReturnFirstActivityAndStatus_StatusOk()
void
getUsers_ShouldReturnAllUsersRegisteredInActivity_StatusOk()
void
isOrganizerOfActivity_ShouldCheckIfOrganizerOfActivity_StatusOk()
void
markAbsent_ShouldMarkAbsentUsers_StatusOk()
void
setup()
void
teardown()
-
-
-
Method Detail
-
setup
@BeforeEach public void setup()
-
teardown
@AfterEach public void teardown()
-
getActivity_ReturnFirstActivityAndStatus_StatusOk
@Test public void getActivity_ReturnFirstActivityAndStatus_StatusOk() throws java.lang.Exception
- Throws:
java.lang.Exception
-
getActivities_ReturnListAndStatus_StatusOk
@Test public void getActivities_ReturnListAndStatus_StatusOk() throws java.lang.Exception
- Throws:
java.lang.Exception
-
createActivity_PostActivity_StatusCreated
@Test public void createActivity_PostActivity_StatusCreated() throws java.lang.Exception
- Throws:
java.lang.Exception
-
editActivity_UpdateActivity_StatusOk
@Test public void editActivity_UpdateActivity_StatusOk() throws java.lang.Exception
- Throws:
java.lang.Exception
-
deleteActivity_ShouldDeleteActivity_StatusOk
@Test public void deleteActivity_ShouldDeleteActivity_StatusOk() throws java.lang.Exception
- Throws:
java.lang.Exception
-
addUserToActivity_ExistingUserAdded_StatusCreated
@Test public void addUserToActivity_ExistingUserAdded_StatusCreated() throws java.lang.Exception
- Throws:
java.lang.Exception
-
markAbsent_ShouldMarkAbsentUsers_StatusOk
@Test public void markAbsent_ShouldMarkAbsentUsers_StatusOk() throws java.lang.Exception
- Throws:
java.lang.Exception
-
isOrganizerOfActivity_ShouldCheckIfOrganizerOfActivity_StatusOk
@Test public void isOrganizerOfActivity_ShouldCheckIfOrganizerOfActivity_StatusOk() throws java.lang.Exception
- Throws:
java.lang.Exception
-
getUsers_ShouldReturnAllUsersRegisteredInActivity_StatusOk
@Test public void getUsers_ShouldReturnAllUsersRegisteredInActivity_StatusOk() throws java.lang.Exception
- Throws:
java.lang.Exception
-
-