Search in sources :

Example 6 with UpdateIssueSubTypeRQ

use of com.epam.ta.reportportal.ws.model.project.config.UpdateIssueSubTypeRQ in project service-api by reportportal.

the class ProjectSettingsControllerTest method updateSubType.

@Test
void updateSubType() throws Exception {
    UpdateIssueSubTypeRQ request = new UpdateIssueSubTypeRQ();
    final UpdateOneIssueSubTypeRQ updateOneIssueSubTypeRQ = new UpdateOneIssueSubTypeRQ();
    updateOneIssueSubTypeRQ.setColor("#000000");
    updateOneIssueSubTypeRQ.setLocator("custom_ti");
    updateOneIssueSubTypeRQ.setLongName("updated");
    updateOneIssueSubTypeRQ.setShortName("upd");
    updateOneIssueSubTypeRQ.setTypeRef("TO_INVESTIGATE");
    request.setIds(Collections.singletonList(updateOneIssueSubTypeRQ));
    mockMvc.perform(put(DEFAULT_PROJECT_BASE_URL + "/settings/sub-type").with(token(oAuthHelper.getDefaultToken())).contentType(APPLICATION_JSON).content(objectMapper.writeValueAsBytes(request))).andExpect(status().isOk());
}
Also used : UpdateOneIssueSubTypeRQ(com.epam.ta.reportportal.ws.model.project.config.UpdateOneIssueSubTypeRQ) UpdateIssueSubTypeRQ(com.epam.ta.reportportal.ws.model.project.config.UpdateIssueSubTypeRQ) BaseMvcTest(com.epam.ta.reportportal.ws.BaseMvcTest) Test(org.junit.jupiter.api.Test)

Aggregations

UpdateIssueSubTypeRQ (com.epam.ta.reportportal.ws.model.project.config.UpdateIssueSubTypeRQ)6 ReportPortalUser (com.epam.ta.reportportal.commons.ReportPortalUser)5 ReportPortalException (com.epam.ta.reportportal.exception.ReportPortalException)5 UpdateOneIssueSubTypeRQ (com.epam.ta.reportportal.ws.model.project.config.UpdateOneIssueSubTypeRQ)5 Test (org.junit.jupiter.api.Test)5 Project (com.epam.ta.reportportal.entity.project.Project)3 Predicates (com.epam.ta.reportportal.commons.Predicates)1 BusinessRule (com.epam.ta.reportportal.commons.validation.BusinessRule)1 BusinessRule.expect (com.epam.ta.reportportal.commons.validation.BusinessRule.expect)1 Suppliers (com.epam.ta.reportportal.commons.validation.Suppliers)1 MessageBus (com.epam.ta.reportportal.core.events.MessageBus)1 DefectTypeUpdatedEvent (com.epam.ta.reportportal.core.events.activity.DefectTypeUpdatedEvent)1 PatternUpdatedEvent (com.epam.ta.reportportal.core.events.activity.PatternUpdatedEvent)1 UpdateProjectSettingsHandler (com.epam.ta.reportportal.core.project.settings.UpdateProjectSettingsHandler)1 PatternTemplateRepository (com.epam.ta.reportportal.dao.PatternTemplateRepository)1 ProjectRepository (com.epam.ta.reportportal.dao.ProjectRepository)1 TestItemIssueGroup (com.epam.ta.reportportal.entity.enums.TestItemIssueGroup)1 IssueType (com.epam.ta.reportportal.entity.item.issue.IssueType)1 PatternTemplate (com.epam.ta.reportportal.entity.pattern.PatternTemplate)1 ProjectIssueType (com.epam.ta.reportportal.entity.project.ProjectIssueType)1