summaryrefslogtreecommitdiffstats
path: root/test/functional/news_controller_test.rb
diff options
context:
space:
mode:
authorJean-Philippe Lang <jp_lang@yahoo.fr>2008-02-03 14:38:04 +0000
committerJean-Philippe Lang <jp_lang@yahoo.fr>2008-02-03 14:38:04 +0000
commit1ecef3a95ae0471707ce6490e9c725daabce9d67 (patch)
tree105a30efe4830429418aee5fbed83a6c8b8e4d13 /test/functional/news_controller_test.rb
parentb124501a4e825801024c873304757d3094753f02 (diff)
downloadredmine-1ecef3a95ae0471707ce6490e9c725daabce9d67.tar.gz
redmine-1ecef3a95ae0471707ce6490e9c725daabce9d67.zip
ProjectsController#add_news moved to NewsController#new.
Preview added when adding/editing a news (#590). git-svn-id: http://redmine.rubyforge.org/svn/trunk@1111 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/functional/news_controller_test.rb')
-rw-r--r--test/functional/news_controller_test.rb11
1 files changed, 11 insertions, 0 deletions
diff --git a/test/functional/news_controller_test.rb b/test/functional/news_controller_test.rb
index 8a02345fd..397e928f1 100644
--- a/test/functional/news_controller_test.rb
+++ b/test/functional/news_controller_test.rb
@@ -45,4 +45,15 @@ class NewsControllerTest < Test::Unit::TestCase
assert_template 'index'
assert_not_nil assigns(:newss)
end
+
+ def test_preview
+ get :preview, :project_id => 1,
+ :news => {:title => '',
+ :description => 'News description',
+ :summary => ''}
+ assert_response :success
+ assert_template 'common/_preview'
+ assert_tag :tag => 'fieldset', :attributes => { :class => 'preview' },
+ :content => /News description/
+ end
end