Я изо всех сил пытаюсь сделать утверждение об отсутствии определенного элемента в перечислении. В частности, это мой тест выглядит следующим образом:
// Take an item from a queue of scheduled items...
ItemQueue pendingQueue = schedule.PendingItems; // PendingItems is an IEnumerable<int>
int item = pendingQueue.FirstItem;
// ...process the item...
processor.DoSomethingWith(item);
// ...and the schedule must not contain the item anymore:
Assert.That(schedule.PendingItems, Does.Not.Contain(item));
Конечно, Does.Not.Contain не является допустимым ограничением nUnit. Как я могу выразить это в действительном свободном синтаксисе?