protected void VerifyRaisedEvents() { var expected = ExpectedEvents(); var aggregate = (IAggregate)Aggregate; var published = aggregate.GetUncommittedEvents().OfType <DomainEvent>(); EventsExtensions.CompareEvents(expected.ToArray(), published.ToArray()); }
protected void VerifyExpected() { EventsExtensions.CompareEvents(ExpectedEvents, ExecuteCommand()); }