public void valid_slicing_with_configured_slicing() { var projection = new MyCustomAggregateWithNoSlicer(); projection.AggregateEvents(x => x.Identity <INumbered>(n => n.Number)); projection.Slicer.ShouldBeOfType <EventSlicer <CustomAggregate, int> >(); }
public void assert_invalid_with_incomplete_slicing_rules() { var projection = new MyCustomAggregateWithNoSlicer(); projection.AggregateEvents(x => {}); Exception <InvalidProjectionException> .ShouldBeThrownBy(() => { new MyCustomAggregateWithNoSlicer().AssembleAndAssertValidity(); }); }