Modules selection lost on project form after validation failure (#8012).

git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@5265 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang
2011-03-30 17:16:25 +00:00
parent b12994e12e
commit 8b39f62a4c
3 changed files with 25 additions and 4 deletions
+8
View File
@@ -588,6 +588,14 @@ class ProjectTest < ActiveSupport::TestCase
assert_nil Project.next_identifier
end
def test_enabled_module_names
with_settings :default_projects_modules => ['issue_tracking', 'repository'] do
project = Project.new
project.enabled_module_names = %w(issue_tracking news)
assert_equal %w(issue_tracking news), project.enabled_module_names.sort
end
end
def test_enabled_module_names_should_not_recreate_enabled_modules
project = Project.find(1)