public void SafeInvoke_WhenNullArgs() { bool invoked = false; Event1 += (sender, args) => invoked = true; Event1.SafeInvoke(null, null); invoked.Should().BeTrue(); }
public void SafeInvoke_WhenExplicitArgs() { bool invoked = false; Event1 += (sender, args) => invoked = true; Event1.SafeInvoke(this, new EventArgs()); invoked.Should().BeTrue(); }