public void CreateInstance_UsesPipeline() { var allowNonPublicConstructors = BooleanObjectMother.GetRandomBoolean(); var fakeInstance = new object(); _defaultPipelineMock .Expect(mock => mock.Create(typeof(BaseType1), ParamList.Empty, allowNonPublicConstructors)) .Return(fakeInstance); var instance = _implementation.CreateInstance(allowNonPublicConstructors, typeof(BaseType1), ParamList.Empty); _defaultPipelineMock.VerifyAllExpectations(); Assert.That(instance, Is.SameAs(fakeInstance)); }