summaryrefslogtreecommitdiffstats
path: root/test
diff options
context:
space:
mode:
authorJean-Philippe Lang <jp_lang@yahoo.fr>2013-02-07 19:24:57 +0000
committerJean-Philippe Lang <jp_lang@yahoo.fr>2013-02-07 19:24:57 +0000
commit2cd749955e48e1f24cf429817a71787440ada057 (patch)
treec00b8a314107ed559dd821aab25487c1827ab59d /test
parenteece12ddfde08646a76ac92d961c4d223349cd39 (diff)
downloadredmine-2cd749955e48e1f24cf429817a71787440ada057.tar.gz
redmine-2cd749955e48e1f24cf429817a71787440ada057.zip
Fixed: error raised when copying project wiki with wiki module disabled (#13097).
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@11332 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test')
-rw-r--r--test/unit/project_copy_test.rb9
1 files changed, 9 insertions, 0 deletions
diff --git a/test/unit/project_copy_test.rb b/test/unit/project_copy_test.rb
index cc76852c9..6b505b2b2 100644
--- a/test/unit/project_copy_test.rb
+++ b/test/unit/project_copy_test.rb
@@ -233,6 +233,15 @@ class ProjectCopyTest < ActiveSupport::TestCase
assert_equal "Start page", @project.wiki.start_page
end
+ test "#copy should copy wiki without wiki module" do
+ project = Project.new(:name => 'Copy Test', :identifier => 'copy-test', :enabled_module_names => [])
+ assert_difference 'Wiki.count' do
+ assert project.copy(@source_project)
+ end
+
+ assert project.wiki
+ end
+
test "#copy should copy wiki pages and content with hierarchy" do
assert_difference 'WikiPage.count', @source_project.wiki.pages.size do
assert @project.copy(@source_project)