Example #1
0
        public void Delete()
        {
            int validID = GetValidProductID();

            var response = ProductEndpoints.DeleteProduct(validID).Result;

            Assert.IsTrue(response.StatusCode == System.Net.HttpStatusCode.OK);
        }
Example #2
0
        public async Task <IActionResult> Delete(int id)
        {
            var result = await ProductEndpoints.DeleteProduct(id);

            return(RedirectToAction("Index", "Product"));
        }