diff test/unit/helpers/custom_fields_helper_test.rb @ 1115:433d4f72a19b redmine-2.2

Update to Redmine SVN revision 11137 on 2.2-stable branch
author Chris Cannam
date Mon, 07 Jan 2013 12:01:42 +0000
parents cbb26bc654de
children 622f24f53b42 261b3d9a4903
line wrap: on
line diff
--- a/test/unit/helpers/custom_fields_helper_test.rb	Wed Jun 27 14:54:18 2012 +0100
+++ b/test/unit/helpers/custom_fields_helper_test.rb	Mon Jan 07 12:01:42 2013 +0000
@@ -1,5 +1,5 @@
 # Redmine - project management software
-# Copyright (C) 2006-2011  Jean-Philippe Lang
+# Copyright (C) 2006-2012  Jean-Philippe Lang
 #
 # This program is free software; you can redistribute it and/or
 # modify it under the terms of the GNU General Public License
@@ -20,6 +20,7 @@
 class CustomFieldsHelperTest < ActionView::TestCase
   include CustomFieldsHelper
   include Redmine::I18n
+  include ERB::Util
 
   def test_format_boolean_value
     I18n.locale = 'en'
@@ -32,7 +33,7 @@
     value = CustomValue.new(:value => 'bar', :custom_field => field)
     field.id = 52
 
-    assert_equal '<input id="object_custom_field_values_52" name="object[custom_field_values][52]" type="text" value="bar" />',
+    assert_equal '<input class="foo_cf" id="object_custom_field_values_52" name="object[custom_field_values][52]" type="text" value="bar" />',
       custom_field_tag('object', value)
   end
 
@@ -40,7 +41,7 @@
     field = CustomField.new(:field_format => 'foo')
     field.id = 52
 
-    assert_equal '<input id="object_custom_field_values_52" name="object[custom_field_values][52]" type="text" value="" />',
+    assert_equal '<input class="foo_cf" id="object_custom_field_values_52" name="object[custom_field_values][52]" type="text" value="" />',
       custom_field_tag_for_bulk_edit('object', field)
   end
 end