public async Task Send_XMLDispatchAsync() { var result = await Service.Send(new Visitor { Id = 1 }); var dispatches = Database.XMLDispatchManager.GetAll(); var dispatch = await Database.XMLDispatchManager.GetByIdAsync(1); //assert Assert.AreEqual(2, dispatches.Count()); Assert.IsTrue(result.Succedeed); Assert.IsNotNull(dispatch); Assert.AreEqual(Status.Send, dispatch.Status); Assert.AreEqual(Operation.Done, dispatch.Operation); }
private async Task SendVisitor(VisitorDTO visitor) { Visitor v = new Visitor { Id = visitor.Id }; await xmlDispatcherService.Send(v); }