public void RemoveValue() { var context = new TestContextBase(); context.SetValue(new TestValueA()); Assert.That(context.Values.Length, Is.EqualTo(1)); Assert.That(context.RemoveValue <TestValueA>(), Is.True); Assert.That(context.Values.Length, Is.Zero); Assert.Throws <InvalidOperationException>(() => context.RemoveValue <object>()); }
public void RemoveValue() { var context = new TestContextBase(); context.SetValue(new TestValueA()); Assert.That(context.Values.Length, Is.EqualTo(1)); Assert.That(context.RemoveValue <TestValueA>(), Is.True); Assert.That(context.Values.Length, Is.Zero); }