Sha256: 4a13ac35bc307f402aefe8fad448e02fff31702ddb056137955574dc9ba64ec4

Contents?: true

Size: 643 Bytes

Versions: 4

Compression:

Stored size: 643 Bytes

Contents

require File.dirname(__FILE__) + '/spec_helper'

describe Formats do
  it "should check if the dictionary is loaded" do
    formats = Formats.new

    formats[:phone]

    formats.should be_loaded(:phone)
  end

  it "should load a dictionary when called by the key" do
    formats = Formats.new

    formats.reset!

    formats.should_not be_loaded(:phone)

    formats[:phone]

    formats.should be_loaded(:phone)
  end

  it "should clear the loaded formats when calling reset!" do
    formats = Formats.new

    formats[:phone]

    formats.should be_loaded(:phone)

    formats.reset!

    formats.should_not be_loaded(:phone)
  end
end

Version data entries

4 entries across 4 versions & 2 rubygems

Version Path
sevenwire-forgery-0.2.0 spec/formats_spec.rb
sevenwire-forgery-0.2.1 spec/formats_spec.rb
sevenwire-forgery-0.2.2 spec/formats_spec.rb
forgery-0.2.2 spec/formats_spec.rb