public static async Task Dispose(MockAgent agent) { agent.Context.Wallet.Dispose(); await agent.Context.Wallet.CloseAsync(); }
public void RegisterAgent(MockAgent agent) { Func <(string name, byte[] data), Task <MessageContext> > function = async(cb) => await agent.HandleInboundAsync(new PackedMessageContext(cb.data)); _agentInBoundCallBacks.Add((agent.Name, function)); }