public Task <ApiResponse <Unit> > Handle(HattemSessionMock session, ErrorNotification notification)
        {
            var error = new TestError();

            return(ApiResponse
                   .Error(error)
                   .AsTask());
        }
        public Task <ApiResponse <CommandMockReturn> > Execute(HattemSessionMock connection, CommandWithReturnMock command)
        {
            var result = _returns[command.Id];

            return(Task.FromResult(result));
        }
        public Task <ApiResponse <QueryMockResult> > Handle(HattemSessionMock connection, AnotherStructQueryMock query)
        {
            var result = _results[query.Id];

            return(Task.FromResult(result));
        }
Ejemplo n.º 4
0
        public Task <ApiResponse <Unit> > Handle(HattemSessionMock session, OrderTrackerNotification notification)
        {
            notification.ExecutedHandlers.Add(GetType());

            return(ApiResponse.OkAsync());
        }
Ejemplo n.º 5
0
        public Task <ApiResponse <Unit> > Handle(HattemSessionMock session, TestNotification notification)
        {
            ExecutedNotifications.Add(notification.Data);

            return(ApiResponse.OkAsync());
        }
        public Task <ApiResponse <Unit> > Execute(HattemSessionMock connection, AnotherCommandMock command)
        {
            var result = _returns[command.Id];

            return(Task.FromResult(result));
        }