OSDN Git Service

Merged r6099 from trunk.
authorJean-Baptiste Barth <jeanbaptiste.barth@gmail.com>
Mon, 20 Jun 2011 01:32:18 +0000 (01:32 +0000)
committerJean-Baptiste Barth <jeanbaptiste.barth@gmail.com>
Mon, 20 Jun 2011 01:32:18 +0000 (01:32 +0000)
Added a test to ensure 'Project' column can be removed on issues list

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/branches/1.2-stable@6100 e93f8b46-1217-0410-a6f0-8f06a7374b81

test/functional/issues_controller_test.rb

index a0edab1..4758cf9 100644 (file)
@@ -267,6 +267,12 @@ class IssuesControllerTest < ActionController::TestCase
     assert_kind_of Hash, session[:query]
     assert_kind_of Array, session[:query][:column_names]
     assert_equal columns, session[:query][:column_names].map(&:to_s)
+
+    # ensure only these columns are kept in the selected columns list
+    assert_tag :tag => 'select', :attributes => { :id => 'selected_columns' },
+                                 :children => { :count => 3 }
+    assert_no_tag :tag => 'option', :attributes => { :value => 'project' },
+                                    :parent => { :tag => 'select', :attributes => { :id => "selected_columns" } }
   end
 
   def test_index_with_custom_field_column