using NUnit.Framework; [TestFixture] public class BareAssertThrowsTests { [Test] public void ExpectsException() { Assert.Throws(() => DoThing()); } private void DoThing() { } }