Example #1
0
        public void GetManagerShouldGet()
        {
            var options = new DbContextOptionsBuilder <SoilMatesContext>().UseInMemoryDatabase("GetManagerShouldGet").Options;

            using var testContext = new SoilMatesContext(options);
            seed(testContext);

            using var assertContext = new SoilMatesContext(options);
            repo = new DBrepo(assertContext);

            var result = repo.GetManagerById(4);

            Assert.NotNull(result);
            Assert.Equal("Babish", result.Name);
        }