public async Task GetTownNamesAsyncShouldReturnOne() { var townRepo = new Repository <Town>(db); var useFullCategory = new Repository <UseFullCategory>(db); var companyRepo = new Repository <Company>(db); var townUseFullCategoriesRepo = new Repository <TownUseFullCategory>(db); var useFullCategoryService = new UseFullCategoryService(useFullCategory, townRepo, townUseFullCategoriesRepo, companyRepo); var townService = new TownService(townRepo, townUseFullCategoriesRepo, useFullCategoryService, companyRepo); await townService.CreateTownByNameAsync("Test"); var allTowns = await townService.GetTownNamesAsync(); var expected = 1; var actual = allTowns.TownsNames.Count; Assert.Equal(expected, actual); }