Skip to content

Commit

Permalink
Add test for escaped interpolations in inconsisten interpolation check
Browse files Browse the repository at this point in the history
  • Loading branch information
Bilka2 committed May 7, 2024
1 parent 6a3e59b commit 24c5b48
Showing 1 changed file with 8 additions and 2 deletions.
10 changes: 8 additions & 2 deletions spec/interpolations_spec.rb
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,14 @@
RSpec.describe 'Interpolations' do
let!(:task) { I18n::Tasks::BaseTask.new }

let(:base_keys) { { 'a' => 'hello %{world}', 'b' => 'foo', 'c' => { 'd' => 'hello %{name}' }, 'e' => 'ok' } }
let(:test_keys) { { 'a' => 'hello', 'b' => 'foo %{bar}', 'c' => { 'd' => 'hola %{amigo}' }, 'e' => 'ok' } }
let(:base_keys) do
{ 'a' => 'hello %{world}', 'b' => 'foo', 'c' => { 'd' => 'hello %{name}' }, 'e' => 'ok', 'f' => '%%{escaped}',
'g' => 'okay' }
end
let(:test_keys) do
{ 'a' => 'hello', 'b' => 'foo %{bar}', 'c' => { 'd' => 'hola %{amigo}' }, 'e' => 'ok', 'f' => 'okay',
'g' => '%%{ignored}' }
end

around do |ex|
TestCodebase.setup(
Expand Down

0 comments on commit 24c5b48

Please sign in to comment.