summaryrefslogtreecommitdiffstats
path: root/test/functional/wiki_controller_test.rb
diff options
context:
space:
mode:
Diffstat (limited to 'test/functional/wiki_controller_test.rb')
-rw-r--r--test/functional/wiki_controller_test.rb7
1 files changed, 7 insertions, 0 deletions
diff --git a/test/functional/wiki_controller_test.rb b/test/functional/wiki_controller_test.rb
index b5325357c..053b86301 100644
--- a/test/functional/wiki_controller_test.rb
+++ b/test/functional/wiki_controller_test.rb
@@ -251,4 +251,11 @@ class WikiControllerTest < Test::Unit::TestCase
assert_response :success
assert_template 'edit'
end
+
+ def test_destroy_attachment
+ @request.session[:user_id] = 2
+ assert_difference 'Attachment.count', -1 do
+ post :destroy_attachment, :id => 1, :page => 'Page_with_an_inline_image', :attachment_id => 3
+ end
+ end
end