diff options
author | Alexandru Croitor <acroitor@gitlab.com> | 2019-05-27 12:42:58 +0300 |
---|---|---|
committer | Alexandru Croitor <acroitor@gitlab.com> | 2019-06-04 13:10:38 +0300 |
commit | 9797b27e1a096f684b870e55aab0b5d1250e73f8 (patch) | |
tree | 91183e82cfeb6159c4946820c584be63b9fe217d /spec/models/milestone_spec.rb | |
parent | 3ef47ac83409cc7e00f7ef80d7cae0434e29ccd2 (diff) |
Adjust burndown chart opened issues count
* Adjust opened issues count in the milestone burndown chart
to match current opened issues in the milestone.
* Fix completion rate calculation to include milestones only.
Diffstat (limited to 'spec/models/milestone_spec.rb')
-rw-r--r-- | spec/models/milestone_spec.rb | 22 |
1 files changed, 0 insertions, 22 deletions
diff --git a/spec/models/milestone_spec.rb b/spec/models/milestone_spec.rb index 752a7965704..e47f2de1ae9 100644 --- a/spec/models/milestone_spec.rb +++ b/spec/models/milestone_spec.rb @@ -182,32 +182,10 @@ describe Milestone do end end - describe '#percent_complete' do - before do - allow(milestone).to receive_messages( - closed_items_count: 3, - total_items_count: 4 - ) - end - - it { expect(milestone.percent_complete(user)).to eq(75) } - end - describe '#can_be_closed?' do it { expect(milestone.can_be_closed?).to be_truthy } end - describe '#total_items_count' do - before do - create :closed_issue, milestone: milestone, project: project - create :merge_request, milestone: milestone, source_project: project - end - - it 'returns total count of issues and merge requests assigned to milestone' do - expect(milestone.total_items_count(user)).to eq 2 - end - end - describe '#can_be_closed?' do before do milestone = create :milestone, project: project |