コード例 #1
0
        public async Task GetActualGoals_Should_Return_NonArchived_And_NotDone_Tasks()
        {
            var expectedCount = 2;

            var result = await _tasksService.GetActualGoals();

            var containsDoneGoals = result.Any(x => x.IsDone || x.IsArchived);

            Assert.Equal(expectedCount, result.Count());
            Assert.False(containsDoneGoals);
        }
コード例 #2
0
        public async Task <IActionResult> Index()
        {
            ViewData["Goals"] = await _tasksService.GetActualGoals();

            return(View(await _tasksService.GetNonArchivedTasks()));
        }