public void ShouldCreateStrictInstanceOfAbstractType() { Interaction i = new Interaction(); MockableBase fooBaseMock = i.CreateStrictMock <MockableBase>(); Specify.That(fooBaseMock).ShouldNotBeNull(); }
public void ShouldThrowExceptionWhenNoMatchingConstructorCanBeFoundForStrictMock() { MethodThatThrows mtt = delegate() { Interaction i = new Interaction(); MockableBase fooBase = i.CreateStrictMock <MockableBase>(1, 2, 3); }; Specify.ThrownBy(mtt).ShouldBeOfType(typeof(NoMatchingConstructorException)); }