summaryrefslogtreecommitdiffstats
path: root/test/unit
diff options
context:
space:
mode:
authorToshi MARUYAMA <marutosijp2@yahoo.co.jp>2019-10-22 15:35:27 +0000
committerToshi MARUYAMA <marutosijp2@yahoo.co.jp>2019-10-22 15:35:27 +0000
commitf0a8ef42f6d159cc139664ac6ccde0079524372c (patch)
tree3b59fe82687c2c3e6d7263ef904472e967603ae5 /test/unit
parent2e6b3b92482b41f626caca641aff9a1707bfffe9 (diff)
downloadredmine-f0a8ef42f6d159cc139664ac6ccde0079524372c.tar.gz
redmine-f0a8ef42f6d159cc139664ac6ccde0079524372c.zip
fix random test failure of ProjectQueryTest (#29482)
git-svn-id: http://svn.redmine.org/redmine/trunk@18827 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/unit')
-rw-r--r--test/unit/project_query_test.rb4
1 files changed, 3 insertions, 1 deletions
diff --git a/test/unit/project_query_test.rb b/test/unit/project_query_test.rb
index e2d151d06..3afafa2a9 100644
--- a/test/unit/project_query_test.rb
+++ b/test/unit/project_query_test.rb
@@ -27,6 +27,8 @@ class ProjectQueryTest < ActiveSupport::TestCase
:enabled_modules,
:custom_fields, :custom_values
+ include Redmine::I18n
+
def test_filter_values_be_arrays
q = ProjectQuery.new
assert_nil q.project
@@ -39,9 +41,9 @@ class ProjectQueryTest < ActiveSupport::TestCase
end
def test_project_statuses_filter_should_return_project_statuses
+ set_language_if_valid 'en'
query = ProjectQuery.new(:name => '_')
query.filters = {'status' => {:operator => '=', :values => []}}
-
values = query.available_filters['status'][:values]
assert_equal ['active', 'closed'], values.map(&:first)
assert_equal ['1', '5'], values.map(&:second)