public void AddDataLoaderRegistry_ServicesIsNull() { // arrange // act Action action = () => DataLoaderServiceCollectionExtensions .AddDataLoaderRegistry(null); // assert Assert.Throws <ArgumentNullException>(action); }
public void AddDataLoaderRegistry() { // arrange var services = new ServiceCollection(); // act DataLoaderServiceCollectionExtensions.AddDataLoaderRegistry(services); // assert services .Select(t => t.ServiceType.GetTypeName()) .OrderBy(t => t) .ToArray() .MatchSnapshot(); }