Example #1
0
        public void Update(ICommand<UserStoryIdentity> command, Action<UserStory> methodToCall)
        {
            var changes = eventStore.GetStream(command.Identity);

            var userStoryState = new UserStoryState(changes);
            var userStory = new UserStory(userStoryState);
            methodToCall(userStory);

            eventStore.AppendToStream(command.Identity, userStory.Changes);
            eventsPublisher.Publish(userStory.Changes);
        }
Example #2
0
 protected override void When()
 {
     userStoryState = new UserStoryState(new List<IEvent>() { new UserStoryCreated(id, name, description), new UserStoryEstimated(id, storyPoints) });
 }
Example #3
0
 public MyUserStory(UserStoryState state)
     : base(state)
 {
 }
 protected override void Given()
 {
     state = new UserStoryState(new List<IEvent>());
     us = new MyUserStory(state);
     ui = new UserStoryIdentity("1");
 }
Example #5
0
 public UserStory(UserStoryState state)
 {
     this.state = state;
 }