public void PostProcurementGood() { GetReady(); var actRes = controller.Post(new ProcurementModel() { Document = "202/71", Date = new DateTime(2016, 12, 22), ProductId = 1, SupplierId = 1, Quantity = 1, Price = 299 }); var response = actRes.ExecuteAsync(CancellationToken.None).Result; Assert.IsTrue(response.IsSuccessStatusCode); }
public void PostProcurementGood() { GetReady(); var actRes = controller.Post(new ProcurementModel() { Quantity = 4, Price = 234, Date = DateTime.UtcNow, Document = "09000083", Supplier = new ProcurementModel.ProcurementSupplier() { Id = 1 }, Product = new ProcurementModel.ProcurementProduct() { Id = 1 } }); var response = actRes.ExecuteAsync(CancellationToken.None).Result; Assert.IsTrue(response.IsSuccessStatusCode); }