mirror of
https://github.com/rails/rails.git
synced 2022-11-09 12:12:34 -05:00
bde6547bb6
The current code base is not uniform. After some discussion, we have chosen to go with double quotes by default.
20 lines
452 B
Ruby
20 lines
452 B
Ruby
require "helper"
|
|
require "jobs/translated_hello_job"
|
|
|
|
class TranslationTest < ActiveSupport::TestCase
|
|
setup do
|
|
JobBuffer.clear
|
|
I18n.available_locales = [:en, :de]
|
|
@job = TranslatedHelloJob.new("Johannes")
|
|
end
|
|
|
|
teardown do
|
|
I18n.available_locales = [:en]
|
|
end
|
|
|
|
test "it performs the job in the given locale" do
|
|
@job.locale = :de
|
|
@job.perform_now
|
|
assert_equal "Johannes says Guten Tag", JobBuffer.last_value
|
|
end
|
|
end
|