summaryrefslogtreecommitdiffstats
path: root/test/functional/wiki_controller_test.rb
diff options
context:
space:
mode:
authorJean-Philippe Lang <jp_lang@yahoo.fr>2017-07-26 16:41:06 +0000
committerJean-Philippe Lang <jp_lang@yahoo.fr>2017-07-26 16:41:06 +0000
commit71423af0b2029922fe1de50bf3b7ccc2315d2e91 (patch)
tree8fa56fc6a36a359bb5ceab4cb2383d7084e2a360 /test/functional/wiki_controller_test.rb
parent1b1a9b6ed58cdda462d9faab46642c11f20c2e15 (diff)
downloadredmine-71423af0b2029922fe1de50bf3b7ccc2315d2e91.tar.gz
redmine-71423af0b2029922fe1de50bf3b7ccc2315d2e91.zip
Get rid of acts_as_versioned.
WikiContent::Version becomes WikiContentVersion. git-svn-id: http://svn.redmine.org/redmine/trunk@16889 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/functional/wiki_controller_test.rb')
-rw-r--r--test/functional/wiki_controller_test.rb24
1 files changed, 12 insertions, 12 deletions
diff --git a/test/functional/wiki_controller_test.rb b/test/functional/wiki_controller_test.rb
index 98d076cbd..7260d9094 100644
--- a/test/functional/wiki_controller_test.rb
+++ b/test/functional/wiki_controller_test.rb
@@ -336,7 +336,7 @@ class WikiControllerTest < Redmine::ControllerTest
@request.session[:user_id] = 2
assert_no_difference 'WikiPage.count' do
assert_no_difference 'WikiContent.count' do
- assert_difference 'WikiContent::Version.count' do
+ assert_difference 'WikiContentVersion.count' do
put :update, :params => {
:project_id => 1,
:id => 'Another_page',
@@ -361,7 +361,7 @@ class WikiControllerTest < Redmine::ControllerTest
@request.session[:user_id] = 2
assert_no_difference 'WikiPage.count' do
assert_no_difference 'WikiContent.count' do
- assert_difference 'WikiContent::Version.count' do
+ assert_difference 'WikiContentVersion.count' do
put :update, :params => {
:project_id => 1,
:id => 'Another_page',
@@ -388,7 +388,7 @@ class WikiControllerTest < Redmine::ControllerTest
@request.session[:user_id] = 2
assert_no_difference 'WikiPage.count' do
assert_no_difference 'WikiContent.count' do
- assert_no_difference 'WikiContent::Version.count' do
+ assert_no_difference 'WikiContentVersion.count' do
put :update, :params => {
:project_id => 1,
:id => 'Another_page',
@@ -414,7 +414,7 @@ class WikiControllerTest < Redmine::ControllerTest
@request.session[:user_id] = 2
assert_no_difference 'WikiPage.count' do
assert_no_difference 'WikiContent.count' do
- assert_no_difference 'WikiContent::Version.count' do
+ assert_no_difference 'WikiContentVersion.count' do
put :update, :params => {
:project_id => 1,
:id => 'Another_page',
@@ -437,7 +437,7 @@ class WikiControllerTest < Redmine::ControllerTest
@request.session[:user_id] = 2
assert_no_difference 'WikiPage.count' do
assert_no_difference 'WikiContent.count' do
- assert_no_difference 'WikiContent::Version.count' do
+ assert_no_difference 'WikiContentVersion.count' do
assert_difference 'Attachment.count' do
put :update, :params => {
:project_id => 1,
@@ -466,7 +466,7 @@ class WikiControllerTest < Redmine::ControllerTest
assert_no_difference 'WikiPage.count' do
assert_no_difference 'WikiContent.count' do
- assert_no_difference 'WikiContent::Version.count' do
+ assert_no_difference 'WikiContentVersion.count' do
put :update, :params => {
:project_id => 1,
:id => 'Another_page',
@@ -514,7 +514,7 @@ class WikiControllerTest < Redmine::ControllerTest
assert_no_difference 'WikiPage.count' do
assert_no_difference 'WikiContent.count' do
- assert_difference 'WikiContent::Version.count' do
+ assert_difference 'WikiContentVersion.count' do
put :update, :params => {
:project_id => 1,
:id => 'Page_with_sections',
@@ -540,7 +540,7 @@ class WikiControllerTest < Redmine::ControllerTest
assert_no_difference 'WikiPage.count' do
assert_no_difference 'WikiContent.count' do
- assert_difference 'WikiContent::Version.count' do
+ assert_difference 'WikiContentVersion.count' do
put :update, :params => {
:project_id => 1,
:id => 'Page_with_sections',
@@ -565,7 +565,7 @@ class WikiControllerTest < Redmine::ControllerTest
assert_no_difference 'WikiPage.count' do
assert_no_difference 'WikiContent.count' do
- assert_no_difference 'WikiContent::Version.count' do
+ assert_no_difference 'WikiContentVersion.count' do
put :update, :params => {
:project_id => 1,
:id => 'Page_with_sections',
@@ -652,7 +652,7 @@ class WikiControllerTest < Redmine::ControllerTest
def test_diff
content = WikiPage.find(1).content
- assert_difference 'WikiContent::Version.count', 2 do
+ assert_difference 'WikiContentVersion.count', 2 do
content.text = "Line removed\nThis is a sample text for testing diffs"
content.save!
content.text = "This is a sample text for testing diffs\nLine added"
@@ -893,7 +893,7 @@ class WikiControllerTest < Redmine::ControllerTest
def test_destroy_version
@request.session[:user_id] = 2
- assert_difference 'WikiContent::Version.count', -1 do
+ assert_difference 'WikiContentVersion.count', -1 do
assert_no_difference 'WikiContent.count' do
assert_no_difference 'WikiPage.count' do
delete :destroy_version, :params => {:project_id => 'ecookbook', :id => 'CookBook_documentation', :version => 2}
@@ -905,7 +905,7 @@ class WikiControllerTest < Redmine::ControllerTest
def test_destroy_invalid_version_should_respond_with_404
@request.session[:user_id] = 2
- assert_no_difference 'WikiContent::Version.count' do
+ assert_no_difference 'WikiContentVersion.count' do
assert_no_difference 'WikiContent.count' do
assert_no_difference 'WikiPage.count' do
delete :destroy_version, :params => {:project_id => 'ecookbook', :id => 'CookBook_documentation', :version => 99}