summaryrefslogtreecommitdiffstats
path: root/test/functional/search_controller_test.rb
diff options
context:
space:
mode:
authorJean-Philippe Lang <jp_lang@yahoo.fr>2015-01-10 10:09:34 +0000
committerJean-Philippe Lang <jp_lang@yahoo.fr>2015-01-10 10:09:34 +0000
commit0ed895388b89c1092f88da7c501587b70c4e899e (patch)
tree7e9537ecc7af04355e6e7dc256a892edef75352d /test/functional/search_controller_test.rb
parent6e94d2f2af616dd3180c1b4eebe35b467198bb2d (diff)
downloadredmine-0ed895388b89c1092f88da7c501587b70c4e899e.tar.gz
redmine-0ed895388b89c1092f88da7c501587b70c4e899e.zip
Option to search open issues only (#10734).
git-svn-id: http://svn.redmine.org/redmine/trunk@13858 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/functional/search_controller_test.rb')
-rw-r--r--test/functional/search_controller_test.rb9
1 files changed, 9 insertions, 0 deletions
diff --git a/test/functional/search_controller_test.rb b/test/functional/search_controller_test.rb
index d57cc0757..924c049b9 100644
--- a/test/functional/search_controller_test.rb
+++ b/test/functional/search_controller_test.rb
@@ -209,6 +209,15 @@ class SearchControllerTest < ActionController::TestCase
assert_equal 2, results.size
end
+ def test_search_open_issues
+ Issue.generate! :subject => 'search_open'
+ Issue.generate! :subject => 'search_open', :status_id => 5
+
+ get :index, :id => 1, :q => 'search_open', :open_issues => '1'
+ results = assigns(:results)
+ assert_equal 1, results.size
+ end
+
def test_search_all_words
# 'all words' is on by default
get :index, :id => 1, :q => 'recipe updating saving', :all_words => '1'