Remove comma from the time system notes

This commit is contained in:
Jose 2018-04-25 15:56:06 -05:00
parent 3d12ce95b1
commit bb650ad052
2 changed files with 2 additions and 8 deletions

View File

@ -159,7 +159,7 @@ module SystemNoteService
body = if noteable.time_estimate == 0
"removed time estimate"
else
"changed time estimate to #{parsed_time},"
"changed time estimate to #{parsed_time}"
end
create_note(NoteSummary.new(noteable, project, author, body, action: 'time_tracking'))

View File

@ -909,13 +909,7 @@ describe SystemNoteService do
it 'sets the note text' do
noteable.update_attribute(:time_estimate, 277200)
expect(subject.note).to eq "changed time estimate to 1w 4d 5h,"
end
it 'appends a comma to separate the note from the update_at time' do
noteable.update_attribute(:time_estimate, 277200)
expect(subject.note).to end_with(',')
expect(subject.note).to eq "changed time estimate to 1w 4d 5h"
end
end