Display of multi custom fields.

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@8726 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang
2012-01-29 22:01:40 +00:00
parent 0cd62a3c77
commit 79b12c73d9
7 changed files with 30 additions and 6 deletions
@@ -563,6 +563,18 @@ class TimelogControllerTest < ActionController::TestCase
assert @response.body.include?("\n04/21/2007,redMine Admin,Design,eCookbook,3,Bug,Error 281 when updating a recipe,1.0,\"\",\"\"\n")
end
def test_index_csv_export_with_multi_custom_field
field = TimeEntryCustomField.create!(:name => 'Test', :field_format => 'list',
:multiple => true, :possible_values => ['value1', 'value2'])
entry = TimeEntry.find(1)
entry.custom_field_values = {field.id => ['value1', 'value2']}
entry.save!
get :index, :project_id => 1, :format => 'csv'
assert_response :success
assert_include '"value1, value2"', @response.body
end
def test_csv_big_5
user = User.find_by_id(3)
user.language = "zh-TW"