parent
c981a555ad
commit
51d0219a1a
@ -0,0 +1,12 @@
|
||||
using Autofac;
|
||||
using NSubstitute;
|
||||
|
||||
namespace TestLibrary;
|
||||
|
||||
public static class AutofacTestExtensions
|
||||
{
|
||||
public static void RegisterMockFor<T>(this ContainerBuilder builder) where T : class
|
||||
{
|
||||
builder.RegisterInstance(Substitute.For<T>()).As<T>();
|
||||
}
|
||||
}
|
Loading…
Reference in new issue