public void CreateProjectWithNameEqual() { #region Parameters List <string> dataProject = ProjectsBDSteps.ReturnProjectByName(); string name = dataProject[0]; string nameStatus = "development"; string labelStatus = "development"; string description = "Report problems with the actual bug tracker here."; string file_path = "/tmp/"; string nameView_state = "public"; string labelView_state = "public"; //Expected Result string statusCodeExpected = "InternalServerError"; #endregion #region Request createProjet = new POST_CreateProjectRequest(); createProjet.SetJsonBody(name, nameStatus, labelStatus, description, file_path, nameView_state, labelView_state); response = createProjet.ExecuteRequest(); #endregion #region Asserts Assert.Multiple(() => { Assert.AreEqual(statusCodeExpected, response.StatusCode.ToString()); }); #endregion }
public void CreateSubProjectErro() { #region Parameters //Remove Hierarchy exist ProjectsBDSteps.DeleteHierarchyProject(); List <string> dataProjectId = ProjectsBDSteps.ReturnProjectByName(); string idProject = dataProjectId[0]; List <string> dataProjectName = ProjectsBDSteps.ReturnProjectByNameRandom(); string name = dataProjectName[0]; // Expected Result string statusCodeExpected = "BadRequest"; #endregion #region Request subProjeto = new POST_CreateSubProjectResquest(idProject); subProjeto.SetJosnBoby(name); response = subProjeto.ExecuteRequest(); #endregion #region Assert Assert.AreEqual(statusCodeExpected, response.StatusCode.ToString()); #endregion }