Class: Artisan::StoryBoard

Inherits:
Object
  • Object
show all
Defined in:
lib/artisan/story_board.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(iteration) ⇒ StoryBoard

Returns a new instance of StoryBoard.



7
8
9
# File 'lib/artisan/story_board.rb', line 7

def initialize(iteration)
  @iteration = iteration
end

Instance Attribute Details

#iterationObject (readonly)

Returns the value of attribute iteration.



5
6
7
# File 'lib/artisan/story_board.rb', line 5

def iteration
  @iteration
end

Instance Method Details

#backlog_totalObject



23
24
25
# File 'lib/artisan/story_board.rb', line 23

def backlog_total
  Artisan::Stories::StoriesInteractor.new(iteration.project).backlog.points
end

#complete_totalObject



35
36
37
# File 'lib/artisan/story_board.rb', line 35

def complete_total
  completed.inject(0) { |sum, story| sum + story.estimate }
end

#completedObject



19
20
21
# File 'lib/artisan/story_board.rb', line 19

def completed
  repository.completed(iteration)
end

#readyObject



11
12
13
# File 'lib/artisan/story_board.rb', line 11

def ready
  repository.ready(iteration)
end

#ready_totalObject



27
28
29
# File 'lib/artisan/story_board.rb', line 27

def ready_total
  ready.inject(0) { |sum, story| sum + story.estimate }
end

#workingObject



15
16
17
# File 'lib/artisan/story_board.rb', line 15

def working
  repository.working(iteration)
end

#working_totalObject



31
32
33
# File 'lib/artisan/story_board.rb', line 31

def working_total
  working.inject(0) { |sum, story| sum + story.estimate }
end