public void AssertionFailsIfAnExceptionIsThrownCustom() { var thing = new EventMocker(); Assert.ThrowsException <InvalidOperationException>(() => AssertExtension.DoesNotTriggerEvent <EventMocker.CustomEventArgs>(x => thing.SomeTypedEvent += x, () => thing.ThrowException())); }
public void AssertionFailsIfAnExceptionIsThrown() { var thing = new EventMocker(); Assert.ThrowsException <InvalidOperationException>(() => AssertExtension.TriggersEvent(x => thing.SomeEvent += x, () => thing.ThrowException())); }