public async Task <IActionResult> UpdateDeliveryPoint([FromBody] DeliveryPointModelDTO deliveryPointModelDto) { try { using (loggingHelper.RMTraceManager.StartTrace("WebService.UpdateDeliveryPoint")) { UpdateDeliveryPointModelDTO updateDeliveryPointModelDTO = null; string methodName = typeof(DeliveryPointController) + "." + nameof(UpdateDeliveryPoint); loggingHelper.LogMethodEntry(methodName, priority, entryEventId); if (!ModelState.IsValid) { return(BadRequest(ModelState)); } updateDeliveryPointModelDTO = await businessService.UpdateDeliveryPointLocation(deliveryPointModelDto); loggingHelper.LogMethodExit(methodName, priority, exitEventId); return(Ok(updateDeliveryPointModelDTO)); } } catch (AggregateException ae) { foreach (var exception in ae.InnerExceptions) { loggingHelper.Log(exception, TraceEventType.Error); } var realExceptions = ae.Flatten().InnerException; throw realExceptions; } }
public async Task Test_UpdateDeliveryPointLocation_PositiveScenario() { UpdateDeliveryPointModelDTO result = await testCandidate.UpdateDeliveryPointLocation(deliveryPointModelDTO); Assert.IsNotNull(result); }