public void applies_to_type(Type eventType, bool shouldApply)
        {
            var aggregate = new SampleAggregate();

            aggregate.AppliesTo(new Type[] { eventType })
            .ShouldBe(shouldApply);
        }
        public void adding_filter_for_aggregate_type()
        {
            var projection = new SampleAggregate();

            projection.CompileAndAssertValidity();

            using var store = DocumentStore.For(ConnectionSource.ConnectionString);
            var filters = projection.BuildFilters(store);

            var filter = filters.OfType <AggregateTypeFilter>().Single();

            filter.AggregateType.ShouldBe(typeof(MyAggregate));
        }