public async Task TestUpdateDevice(UpdateHardwareRequest obj, ObjectResult resultAction, bool elementCreated = false) { HardwareResponse defaultCompany = await this.CreatedDefaultHardware(); obj.Id = elementCreated == true ? defaultCompany.Id : obj.Id; IActionResult actionResult = await this.UpdateHardware(obj); base.CheckAssert(actionResult, resultAction); }
public async Task TestGetHardware(GetHardwareByIdRequest getcom, ObjectResult resultAction, bool elementCreated = false) { HardwareResponse defaultHardware = await this.CreatedDefaultHardware(); getcom.Id = elementCreated == true ? defaultHardware.Id : getcom.Id; IActionResult actionResult = await this.GetHardwareById(getcom); base.CheckAssert(actionResult, resultAction); }
public async Task TestDeleteHardware(DeleteHardwareByIdRequest delnot, ObjectResult resultAction, bool elementCreated = false) { HardwareResponse defaultHardware = await this.CreatedDefaultHardware(); //Guid createdtransactionId = CompanyComponentsValues.GetCompanyAviability(); delnot.Id = elementCreated == true ? defaultHardware.Id : delnot.Id; IActionResult actionResult = await this.DeleteHardware(delnot); base.CheckAssert(actionResult, resultAction); }