public void Adds_node_to_store_on_NodeRegistered_message() { const ulong Id = 4; const string Type = "test"; var msg = new NodeRegistered(new RegisterMessage { Id = Id, Type = Type }, new IPEndPoint(IPAddress.Loopback, 123)); tracker.Handle(msg); A.CallTo(() => store.AddNode(Id, Type, A <IReadOnlyList <string> > .Ignored)) .MustHaveHappened(Repeated.Exactly.Once); }
public void Handle(NodeRegistered notification) { logger.Debug($"Registering new node {notification.Message.Id}."); csDataStore.AddNode(notification.Message.Id, notification.Message.Type, notification.Message.SolvableProblems); }