public async Task CountExpressionsAsync_Grades_CountsCorrectly() { using var context = new UniversityContext(builder.Options); var repository = new GradeRepository(context); // From UniversityContext OnModelCreating var initialNumber = 2; var count = await repository.CountAsync(grade => grade.StudentId == 3); Assert.That(count, Is.EqualTo(initialNumber)); }