Ejemplo n.º 1
0
            public TResult Dispatch <TResult>(Func <FakeStore, TResult> query)
            {
                FakeStore current = _db.Store.Copy();

                CommitTo(current);
                return(query(current));
            }
Ejemplo n.º 2
0
 public EnderecoConsumer(ILogger <EnderecoConsumer> logger, IPublishEndpoint publishEndpoint,
                         FakeStore fakeStore)
 {
     _logger          = logger;
     _publishEndPoint = publishEndpoint;
     _fakeStore       = fakeStore;
 }
 public UsersController(IOptions <RabbitmqConfig> rabbitConfig,
                        ISendEndpointProvider sendEndpoint, IPublishEndpoint publish, FakeStore fakeStore)
 {
     _fakeStore       = fakeStore;
     _rabbitConfig    = rabbitConfig.Value;
     _sendEndpoint    = sendEndpoint;
     _publishEndPoint = publish;
 }
 public SubscribeToCompanyConsumer(IOptions <RabbitmqConfig> rabbitConfig,
                                   ISendEndpointProvider sendEndpoint, IPublishEndpoint publish,
                                   FakeStore store)
 {
     _store           = store;
     _rabbitConfig    = rabbitConfig.Value;
     _sendEndpoint    = sendEndpoint;
     _publishEndPoint = publish;
 }
Ejemplo n.º 5
0
        public PullTests()
        {
            timeZone = DateTimeZoneProviders.Tzdb.GetSystemDefault();

            store = new FakeStore();
            storeFactory = new TestStoreFactory(store);

            Emit(NewId<LocalCalendar>(),
                 new RemoteCalendarAdded(
                     new FakeRemote
                     {
                         Id = NewId<RemoteCalendar>()
                     }));
        }
Ejemplo n.º 6
0
        public PullTests()
        {
            timeZone = DateTimeZoneProviders.Tzdb.GetSystemDefault();

            store        = new FakeStore();
            storeFactory = new TestStoreFactory(store);

            Emit(NewId <LocalCalendar>(),
                 new RemoteCalendarAdded(
                     new FakeRemote
            {
                Id = NewId <RemoteCalendar>()
            }));
        }
Ejemplo n.º 7
0
 private void CommitTo(FakeStore s)
 {
     _log.Actions.ForEach(a => a.Execute(s));
 }
 public CompaniesController(FakeStore store)
 {
     _store = store;
 }
Ejemplo n.º 9
0
 private FakeStore(FakeStore other)
 {
     _docs = other._docs;
 }