Commit a54c2775 authored by jplang's avatar jplang

Reset locale to "en" before helpers tests.

git-svn-id: https://svn.redmine.org/redmine/trunk@16232 e93f8b46-1217-0410-a6f0-8f06a7374b81
parent 91ad7224
......@@ -278,9 +278,12 @@ module Redmine
end
class HelperTest < ActionView::TestCase
include Redmine::I18n
def setup
super
User.current = nil
::I18n.locale = 'en'
end
end
......
......@@ -19,7 +19,6 @@ require File.expand_path('../../../test_helper', __FILE__)
class ActivitiesHelperTest < Redmine::HelperTest
include ActivitiesHelper
include Redmine::I18n
class MockEvent
attr_reader :event_datetime, :event_group, :name
......
......@@ -20,7 +20,6 @@
require File.expand_path('../../../test_helper', __FILE__)
class ApplicationHelperTest < Redmine::HelperTest
include Redmine::I18n
include ERB::Util
include Rails.application.routes.url_helpers
......
......@@ -20,7 +20,6 @@ require File.expand_path('../../../test_helper', __FILE__)
class CustomFieldsHelperTest < Redmine::HelperTest
include ApplicationHelper
include CustomFieldsHelper
include Redmine::I18n
include ERB::Util
def test_format_boolean_value
......
......@@ -18,7 +18,6 @@
require File.expand_path('../../../test_helper', __FILE__)
class GroupsHelperTest < Redmine::HelperTest
include Redmine::I18n
include ERB::Util
include GroupsHelper
include Rails.application.routes.url_helpers
......
......@@ -18,7 +18,6 @@
require File.expand_path('../../../test_helper', __FILE__)
class IssuesHelperTest < Redmine::HelperTest
include Redmine::I18n
include IssuesHelper
include CustomFieldsHelper
include ERB::Util
......@@ -35,11 +34,6 @@ class IssuesHelperTest < Redmine::HelperTest
:attachments,
:versions
def setup
super
set_language_if_valid('en')
end
def test_issue_heading
assert_equal "Bug #1", issue_heading(Issue.find(1))
end
......
......@@ -18,7 +18,6 @@
require File.expand_path('../../../test_helper', __FILE__)
class MembersHelperTest < Redmine::HelperTest
include Redmine::I18n
include ERB::Util
include MembersHelper
include Rails.application.routes.url_helpers
......
......@@ -18,7 +18,6 @@
require File.expand_path('../../../test_helper', __FILE__)
class MyHelperTest < Redmine::HelperTest
include Redmine::I18n
include ERB::Util
include MyHelper
......
......@@ -20,7 +20,6 @@ require File.expand_path('../../../test_helper', __FILE__)
class ProjectsHelperTest < Redmine::HelperTest
include ApplicationHelper
include ProjectsHelper
include Redmine::I18n
include ERB::Util
include Rails.application.routes.url_helpers
......@@ -33,11 +32,6 @@ class ProjectsHelperTest < Redmine::HelperTest
:groups_users,
:enabled_modules
def setup
super
set_language_if_valid('en')
end
def test_link_to_version_within_project
@project = Project.find(2)
User.current = User.find(1)
......
......@@ -19,7 +19,6 @@ require File.expand_path('../../../test_helper', __FILE__)
class QueriesHelperTest < Redmine::HelperTest
include QueriesHelper
include Redmine::I18n
fixtures :projects, :enabled_modules, :users, :members,
:member_roles, :roles, :trackers, :issue_statuses,
......
......@@ -21,7 +21,6 @@ require File.expand_path('../../../test_helper', __FILE__)
class SearchHelperTest < Redmine::HelperTest
include SearchHelper
include Redmine::I18n
include ERB::Util
def test_highlight_single_token
......
......@@ -19,7 +19,6 @@ require File.expand_path('../../../test_helper', __FILE__)
class SettingsHelperTest < Redmine::HelperTest
include SettingsHelper
include Redmine::I18n
include ERB::Util
def test_date_format_setting_options_should_include_human_readable_format
......
......@@ -19,7 +19,6 @@ require File.expand_path('../../../test_helper', __FILE__)
class SortHelperTest < Redmine::HelperTest
include SortHelper
include Redmine::I18n
include ERB::Util
def setup
......
......@@ -19,7 +19,6 @@ require File.expand_path('../../../test_helper', __FILE__)
class TimelogHelperTest < Redmine::HelperTest
include TimelogHelper
include Redmine::I18n
include ActionView::Helpers::TextHelper
include ActionView::Helpers::DateHelper
include ERB::Util
......
......@@ -19,16 +19,10 @@ require File.expand_path('../../../test_helper', __FILE__)
class WatchersHelperTest < Redmine::HelperTest
include WatchersHelper
include Redmine::I18n
include Rails.application.routes.url_helpers
fixtures :users, :issues
def setup
super
set_language_if_valid('en')
end
test '#watcher_link with a non-watched object' do
expected = link_to(
"Watch",
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment