Time entries CSV export should include the tracker and subject of the issue (#18269).

git-svn-id: http://svn.redmine.org/redmine/trunk@13562 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang
2014-11-05 15:23:22 +00:00
parent 4c9fcb34b6
commit b2ba7db4e1
2 changed files with 18 additions and 4 deletions

View File

@@ -716,4 +716,14 @@ class TimelogControllerTest < ActionController::TestCase
assert_equal 'text/csv; header=present', response.content_type
end
end
def test_index_csv_should_fill_issue_column_with_tracker_id_and_subject
issue = Issue.find(1)
entry = TimeEntry.generate!(:issue => issue, :comments => "Issue column content test")
get :index, :format => 'csv'
line = response.body.split("\n").detect {|l| l.include?(entry.comments)}
assert_not_nil line
assert_include "#{issue.tracker} #1: #{issue.subject}", line
end
end