public void MultipleArrivalStopsCancelled() { ResolvedServiceStop[] services = { TestSchedules.CreateResolvedArrivalStop("A98765"), TestSchedules.CreateResolvedArrivalStop(isCancelled: true), TestSchedules.CreateResolvedArrivalStop("Z12345"), TestSchedules.CreateResolvedArrivalStop("X98765", isCancelled: true) }; var notCancelled = FilterCancelled(services); Assert.Equal(2, notCancelled.Length); Assert.Contains(services[0], notCancelled); Assert.Contains(services[2], notCancelled); }
public void DedupMultipleDifferentArrivalStops() { ResolvedServiceStop[] services = { TestSchedules.CreateResolvedArrivalStop("A98765"), TestSchedules.CreateResolvedArrivalStop(isCancelled: true), TestSchedules.CreateResolvedArrivalStop("Z12345"), TestSchedules.CreateResolvedArrivalStop("X98765", isCancelled: true) }; var deduped = Deduplicate(services); Assert.Equal(2, deduped.Length); Assert.Contains(services[0], deduped); Assert.Contains(services[2], deduped); }