summaryrefslogtreecommitdiffstats
path: root/test/functional/previews_controller_test.rb
diff options
context:
space:
mode:
Diffstat (limited to 'test/functional/previews_controller_test.rb')
-rw-r--r--test/functional/previews_controller_test.rb8
1 files changed, 8 insertions, 0 deletions
diff --git a/test/functional/previews_controller_test.rb b/test/functional/previews_controller_test.rb
index f99ccb401..490e62320 100644
--- a/test/functional/previews_controller_test.rb
+++ b/test/functional/previews_controller_test.rb
@@ -54,6 +54,14 @@ class PreviewsControllerTest < ActionController::TestCase
assert_tag :p, :content => 'Foo'
end
+ def test_preview_issue_notes_should_support_links_to_existing_attachments
+ Attachment.generate!(:container => Issue.find(1), :filename => 'foo.bar')
+ @request.session[:user_id] = 2
+ post :issue, :project_id => '1', :id => 1, :notes => 'attachment:foo.bar'
+ assert_response :success
+ assert_select 'a.attachment', :text => 'foo.bar'
+ end
+
def test_preview_new_news
get :news, :project_id => 1,
:news => {:title => '',