public void Delete() { int validID = GetValidProductID(); var response = ProductEndpoints.DeleteProduct(validID).Result; Assert.IsTrue(response.StatusCode == System.Net.HttpStatusCode.OK); }
public async Task <IActionResult> Delete(int id) { var result = await ProductEndpoints.DeleteProduct(id); return(RedirectToAction("Index", "Product")); }