public BacklogItems.BacklogItem PlanBacklogItem( BacklogItemId newBacklogItemId, String summary, String category, BacklogItemType type, StoryPoints storyPoints) { var backlogItem = new BacklogItems.BacklogItem( this.TenantId, this.ProductId, newBacklogItemId, summary, category, type, BacklogItemStatus.Planned, storyPoints); DomainEventPublisher .Instance .Publish(new ProductBacklogItemPlanned( backlogItem.TenantId, backlogItem.ProductId, backlogItem.BacklogItemId, backlogItem.Summary, backlogItem.Category, backlogItem.Type, backlogItem.StoryPoints)); return(backlogItem); }
public BacklogItemTypeChanged(TenantId tenantId, BacklogItemId backlogItemId, BacklogItemType backlogItemType) { this.TenantId = tenantId; this.BacklogItemId = backlogItemId; this.BacklogItemType = backlogItemType; this.EventVersion = 1; this.OccurredOn = DateTime.Now; }
public BacklogItemTypeChanged(Tenants.TenantId tenantId, BacklogItemId backlogItemId, BacklogItemType type) { TenantId = tenantId; EventVersion = 1; OccurredOn = DateTime.UtcNow; BacklogItemId = backlogItemId; BacklogItemType = type; }
private async Task <string> CreateSampleCustomField(BacklogItemType type) { return((await CreateSampleCustomField( f => { f.BacklogItemTypes = new BacklogItemType?[] { type }; f.Name = "Test Custom Field +" + type; })).Id); }
public ProductBacklogItemPlanned(TenantId tenantId, ProductId productId, BacklogItemId backlogItemId, string summary, string category, BacklogItemType backlogItemType, StoryPoints storyPoints) { this.TenantId = tenantId; this.ProductId = productId; this.BacklogItemId = backlogItemId; this.Summary = summary; this.Category = category; this.BacklogItemType = backlogItemType; this.StoryPoints = storyPoints; this.EventVersion = 1; this.OccurredOn = DateTime.Now; }
public BacklogItem(TenantId tenantId, ProductId productId, BacklogItemId backlogItemId, string summary, string category, BacklogItemType type, BacklogItemStatus backlogItemStatus, StoryPoints storyPoints) { AssertionConcern.NotEmpty(summary, "The summary must be provided."); AssertionConcern.Length(summary, 100, "The summary must be 100 characters or less."); this.TenantId = tenantId; this.ProductId = productId; this.BacklogItemId = backlogItemId; this.Summary = summary; this.Category = category; this.Type = type; this.Status = backlogItemStatus; this.StoryPoints = storyPoints; this._tasks = new List<Task>(); }
public ProductBacklogItemPlanned( TenantId tenantId, ProductId productId, BacklogItemId backlogItemId, string summary, string category, BacklogItemType backlogItemType, StoryPoints storyPoints) { BacklogItemId = backlogItemId; Category = category; EventVersion = 1; OccurredOn = DateTime.Now; ProductId = productId; StoryPoints = storyPoints; Summary = summary; TenantId = tenantId; Type = backlogItemType; }
public BacklogItem( TenantId tenantId, ProductId productId, BacklogItemId backlogItemId, string summary, string category, BacklogItemType type, BacklogItemStatus backlogItemStatus, StoryPoints storyPoints) { this.BacklogItemId = backlogItemId; this.Category = category; this.ProductId = productId; this.Status = backlogItemStatus; this.StoryPoints = storyPoints; this.Summary = summary; this.TenantId = tenantId; this.Type = type; }
public BacklogItem( TenantId tenantId, ProductId productId, BacklogItemId backlogItemId, string summary, string category, BacklogItemType type, BacklogItemStatus backlogItemStatus, StoryPoints storyPoints) { BacklogItemId = backlogItemId; Category = category; ProductId = productId; Status = backlogItemStatus; StoryPoints = storyPoints; Summary = summary; TenantId = tenantId; Type = type; _tasks = new List <Task.Task>(); }
public BacklogItem( TenantId tenantId, ProductId productId, BacklogItemId backlogItemId, string summary, string category, BacklogItemType type, BacklogItemStatus backlogItemStatus, StoryPoints storyPoints) { this.BacklogItemId = backlogItemId; this.Category = category; this.ProductId = productId; this.Status = backlogItemStatus; this.StoryPoints = storyPoints; this.Summary = summary; this.TenantId = tenantId; this.Type = type; this.tasks = new List <Task>(); }
private async Task Querying_By_Type_Works(BacklogItemType type, int expectedRecordCount) { // GIVEN two backlog items: a bug and a user story var bugRef = await CreateBacklogItem <BugAddUpdRequest>(); var usRef = await CreateBacklogItem <UserStoryAddUpdRequest>(); // WHEN querying by type var items = await _queryService.GetList(new BacklogItemListGetRequest { Type = type }); // THEN // the returned number of records is correct Assert.Equal(expectedRecordCount, items.TotalRecords); if (expectedRecordCount == 1) { // with correct type Assert.Equal(type, items.Entries.First().Type); // and with correct ID Assert.Equal((type == BacklogItemType.Bug) ? bugRef.Id : usRef.Id, items.Entries.First().Id); } }
public BacklogItem PlanBacklogItem(BacklogItemId newBacklogItemId, string summary, string category, BacklogItemType type, StoryPoints storyPoints) { BacklogItem backlogItem = new BacklogItem(this.TenantId, this.ProductId, newBacklogItemId, summary, category, type, BacklogItemStatus.Planned, storyPoints); DomainEventPublisher.Instance.Publish(new ProductBacklogItemPlanned(backlogItem.TenantId, backlogItem.ProductId, backlogItem.BacklogItemId, backlogItem.Summary, backlogItem.Category, backlogItem.Type, backlogItem.StoryPoints)); return backlogItem; }
public void ChangeType(BacklogItemType type) { Type = type; DomainEventPublisher.Instance.Publish( new BacklogItemTypeChanged(TenantId, BacklogItemId, type)); }
public void ChangeType(BacklogItemType type) { this.Type = type; DomainEventPublisher.Instance.Publish( new BacklogItemTypeChanged(this.TenantId, this.BacklogItemId, type)); }