Sha256: 35b832de8fa5d0881dc8fed6265dcfac47a807e241d1ff735e349d8ebbaf9fae

Contents?: true

Size: 546 Bytes

Versions: 10

Compression:

Stored size: 546 Bytes

Contents

require File.expand_path('spec/spec_helper')

describe 'unconfigured' do
  it "gives a useful error message when trying to just translate" do
    FastGettext.text_domain = nil
    begin
      FastGettext._('x')
      "".should == "success!?"
    rescue FastGettext::Storage::NoTextDomainConfigured
    end
  end

  it "gives a useful error message when only locale was set" do
    FastGettext.locale = 'de'
    begin
      FastGettext._('x')
      "".should == "success!?"
    rescue FastGettext::Storage::NoTextDomainConfigured
    end
  end
end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
fast_gettext-0.6.6 spec/aa_unconfigued_spec.rb
fast_gettext-0.6.5 spec/aa_unconfigued_spec.rb
fast_gettext-0.6.4 spec/aa_unconfigued_spec.rb
fast_gettext-0.6.3 spec/aa_unconfigued_spec.rb
fast_gettext-0.6.2 spec/aa_unconfigued_spec.rb
fast_gettext-0.6.1 spec/aa_unconfigued_spec.rb
fast_gettext-0.6.0 spec/aa_unconfigued_spec.rb
fast_gettext-0.5.13 spec/aa_unconfigued_spec.rb
fast_gettext-0.5.12 spec/aa_unconfigued_spec.rb
fast_gettext-0.5.11 spec/aa_unconfigued_spec.rb