public void GivenANullEntityThrowArgumentNullException() { Action <string> callback = str => { }; var target = new ActionObserver <string>(callback); Action act = () => target.OnNext(null); }
public void GivenAnEntityIsSuppliedThenCallbackIsInvoked() { var callbackInvoked = false; Action <string> callback = str => { callbackInvoked = true; }; var target = new ActionObserver <string>(callback); target.OnNext(""); callbackInvoked.Should().BeTrue(); }
public void GivenOnCompleteHasBeenCalledThenCallbackIsNotInvoked() { var callbackInvoked = false; Action <string> callback = str => { callbackInvoked = true; }; var target = new ActionObserver <string>(callback); target.OnCompleted(); target.OnNext(""); callbackInvoked.Should().BeFalse(); }