public void StopListening_NoMoreResponsesReceived() { const string expectedKey = "key"; var registration = new EventOfInterestRegistration(expectedKey, FirstResponse, EEventOfInterestType.Persistant); _service.ListenForEventOfInterest(registration); _service.StopListeningForEventOfInterest(registration); _service.RecordEventOfInterest(expectedKey); Assert.IsFalse(_firstEventTriggered); }
private void RegisterForEventsOfInterest() { var eventsOfInterest = _eventsOfInterestService.Get(); _registrations = new List <EventOfInterestRegistration>(_chatterEntries.Count); foreach (var chatterEntry in _chatterEntries) { var registration = new EventOfInterestRegistration(chatterEntry.Key, OnEventOfInterest, chatterEntry.Value.ChatterType); eventsOfInterest.ListenForEventOfInterest(registration); _registrations.Add(registration); } }
public void StopListeningForEventOfInterest(EventOfInterestRegistration registration) { StopListeningEvents.Add(registration); }
public void ListenForEventOfInterest(EventOfInterestRegistration registration) { ListenedEvents.Add(registration); }