public async Task Handle(ProposalCreated message) { Data.ProposalId = message.ProposalId; Data.ProposalCreated = true; Log.Information($"ProposalId -> {message.ProposalId}"); await _bus.Send(new SendProposalByEmail() { ProposalId = message.ProposalId, Name = message.Name, Email = message.Email }); TryComplete(); }
public async Task ProcessAsync_Test() { var proposalCreated = new ProposalCreated { ProposalId = HashHelper.ComputeFrom("Test") }; var transactionResult = new TransactionResult { Logs = { new LogEvent { Name = "ProposalCreated", NonIndexed = proposalCreated.ToByteString() } } }; var logEventsMap = new Dictionary <TransactionResult, List <LogEvent> >(); // use default auditor logEventsMap[transactionResult] = new List <LogEvent> { new LogEvent() }; await _logEventProcessor.ProcessAsync(new Block(), logEventsMap); }