summaryrefslogtreecommitdiffstats
path: root/test/functional/wiki_controller_test.rb
diff options
context:
space:
mode:
authorMarius Balteanu <marius.balteanu@zitec.com>2022-02-18 08:03:52 +0000
committerMarius Balteanu <marius.balteanu@zitec.com>2022-02-18 08:03:52 +0000
commitd8263dcdee13b27ea4ac56c28d10dc2ca7fb8b40 (patch)
tree8cae586bd8ca7b834be34187b17df96ae19d06e6 /test/functional/wiki_controller_test.rb
parentf70d7a3096971c43370247627feee3c0895bb828 (diff)
downloadredmine-d8263dcdee13b27ea4ac56c28d10dc2ca7fb8b40.tar.gz
redmine-d8263dcdee13b27ea4ac56c28d10dc2ca7fb8b40.zip
Return 404 if revision URL doesn't exist (#36561).
Patch by Mizuki ISHIKAWA. git-svn-id: http://svn.redmine.org/redmine/trunk@21413 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/functional/wiki_controller_test.rb')
-rw-r--r--test/functional/wiki_controller_test.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/test/functional/wiki_controller_test.rb b/test/functional/wiki_controller_test.rb
index d5758cb09..64d0a4e48 100644
--- a/test/functional/wiki_controller_test.rb
+++ b/test/functional/wiki_controller_test.rb
@@ -201,6 +201,12 @@ class WikiControllerTest < Redmine::ControllerTest
assert_select 'select[name=?] option[value="2"][selected=selected]', 'wiki_page[parent_id]'
end
+ def test_show_unexistent_version_page
+ @request.session[:user_id] = 2
+ get :show, :params => {:project_id => 1, :id => 'CookBook_documentation', :version => 100}
+ assert_response 404
+ end
+
def test_show_should_not_show_history_without_permission
Role.anonymous.remove_permission! :view_wiki_edits
get :show, :params => {:project_id => 1, :id => 'Page with sections', :version => 2}