Sha256: 9873a189f16eec0f49e0c2cbacae3c954cf7b8cc91ea4abc6a49cbbe1c9c7ed7
Contents?: true
Size: 646 Bytes
Versions: 2
Compression:
Stored size: 646 Bytes
Contents
require 'spec_helper' require File.dirname(__FILE__) + '/../../lib/alephant/renderer/i18n/json' describe Alephant::Renderer::I18n::Json do let(:template_path) { File.join(File.dirname(__FILE__), 'fixtures') } let(:locale) { 'en' } let(:namespace) { 'my_namespace' } subject { described_class.new(locale, namespace, template_path) } describe 'json translations' do let(:params) do { locale: 'cy', count: 1, scope: 'other_namespace' } end it 'should translate a string held in a json document' do expect(subject.t(:some_string, params)).to eq('another string') end end end
Version data entries
2 entries across 2 versions & 1 rubygems
Version | Path |
---|---|
alephant-renderer-3.2.0 | spec/integration/i18n_json_spec.rb |
alephant-renderer-3.1.0 | spec/integration/i18n_json_spec.rb |