public TestableApplication(IdRegistry ids)
 {
     _ids    = ids;
     Planned = new Dictionary <Tuple <Type, TestableId>, object>();
     Added   = new Dictionary <Tuple <Type, TestableId>, object>();
     Updated = new Dictionary <Tuple <Type, TestableId>, object>();
     Deleted = new List <Tuple <Type, TestableId> >();
     Read    = new List <Tuple <Type, TestableId> >();
 }
Beispiel #2
0
        public TestableContext()
        {
            _ids = new IdRegistry();
            _ctx = new TestableMessageHandlerContext();

            UoW       = new TestableDomain(_ids);
            App       = new TestableApplication(_ids);
            Processor = new TestableProcessor();

            _ctx.Extensions.Set <UnitOfWork.IDomain>(UoW);
            _ctx.Extensions.Set <UnitOfWork.IApplication>(App);
            _ctx.Extensions.Set <IProcessor>(Processor);
            _ctx.Extensions.Set <IContainer>(new TestableContainer());
        }
Beispiel #3
0
 /// <summary>
 ///     Create a new claims authority that will use a given ID
 ///     registry.
 /// </summary>
 /// <param name="registry">
 ///     The ID registry to use.
 /// </param>
 public ClaimsAgent(IdRegistry registry)
 {
     this.registry = registry;
 }
Beispiel #4
0
 public TestableDomain(IdRegistry ids)
 {
     _ids          = ids;
     _repositories = new Dictionary <string, IRepository>();
 }