Sha256: 5ea9ae2143da9ca90ae801556c1a155409c70a47cb24857f64fc507a4ce56ee4

Contents?: true

Size: 625 Bytes

Versions: 22

Compression:

Stored size: 625 Bytes

Contents

require "spec_helper"

describe AwesomeTranslations::Handlers::GlobalHandler do
  let(:global_handler) { AwesomeTranslations::Handlers::GlobalHandler.new }
  let(:translations) { global_handler.groups.first.translations.to_a }
  let(:yes_translation) { translations.select { |translation| translation.key == "yes" }.first }

  it "finds the right translations" do
    translations.length.should eq 2
  end

  it "reads the keys right" do
    yes_translation.key.should eq "yes"
  end

  it "sets the correct translation path" do
    yes_translation.dir.should eq "#{Rails.root}/config/locales/awesome_translations"
  end
end

Version data entries

22 entries across 22 versions & 1 rubygems

Version Path
awesome_translations-0.0.24 spec/handlers/global_handler_spec.rb
awesome_translations-0.0.23 spec/handlers/global_handler_spec.rb
awesome_translations-0.0.22 spec/handlers/global_handler_spec.rb
awesome_translations-0.0.21 spec/handlers/global_handler_spec.rb
awesome_translations-0.0.20 spec/handlers/global_handler_spec.rb
awesome_translations-0.0.19 spec/handlers/global_handler_spec.rb
awesome_translations-0.0.18 spec/handlers/global_handler_spec.rb
awesome_translations-0.0.17 spec/handlers/global_handler_spec.rb
awesome_translations-0.0.16 spec/handlers/global_handler_spec.rb
awesome_translations-0.0.15 spec/handlers/global_handler_spec.rb
awesome_translations-0.0.14 spec/handlers/global_handler_spec.rb
awesome_translations-0.0.13 spec/handlers/global_handler_spec.rb
awesome_translations-0.0.12 spec/handlers/global_handler_spec.rb
awesome_translations-0.0.10 spec/handlers/global_handler_spec.rb
awesome_translations-0.0.9 spec/handlers/global_handler_spec.rb
awesome_translations-0.0.8 spec/handlers/global_handler_spec.rb
awesome_translations-0.0.7 spec/handlers/global_handler_spec.rb
awesome_translations-0.0.6 spec/handlers/global_handler_spec.rb
awesome_translations-0.0.5 spec/handlers/global_handler_spec.rb
awesome_translations-0.0.4 spec/handlers/global_handler_spec.rb