public async Task WhenRetrievingAPersonById() { var resolver = new StaticConnectionStringResolver(new Dictionary <string, string> { ["v"] = ConnectionString }); var loader = new DapperPersonLoader(resolver); var expected = Seeded.First(); var actual = await loader.GetAsync(expected.Id); AreEquivalent(expected, actual); }
public async Task WhenRetrievingAllPeople() { var resolver = new StaticConnectionStringResolver(new Dictionary <string, string> { ["v"] = ConnectionString }); var loader = new DapperPersonLoader(resolver); var actual = await loader.GetAsync(); actual.Should().NotBeNull(); actual.Count().Should().Be(Injected.Count() + Seeded.Count()); AreEquivalent(Seeded.Union(Injected), actual); }