class PairSee::CardKnowledgeSummary

Attributes

commits_on_card_count[R]

Public Class Methods

new(card_number, commits_on_card_count, authors) click to toggle source
# File lib/pair_see/card_knowledge_summary.rb, line 6
def initialize(card_number, commits_on_card_count, authors)
  @card_number = card_number
  @commits_on_card_count = commits_on_card_count
  @authors = authors
end

Public Instance Methods

authors_list() click to toggle source
# File lib/pair_see/card_knowledge_summary.rb, line 21
def authors_list
  @authors.sort.join(' ')
end
has_debt() click to toggle source
# File lib/pair_see/card_knowledge_summary.rb, line 12
def has_debt
  @authors.count < 2
end
pretty() click to toggle source
# File lib/pair_see/card_knowledge_summary.rb, line 16
def pretty
  pretty_author_names = @authors.map(&:to_s).join
  "#{@card_number} has #{@commits_on_card_count} commits with only #{@authors.count} committer(s) #{pretty_author_names} on the entire card"
end