Sha256: be790ed59082686c8ebb2a5ef37adee14e06da611a7c9bbb0dcb767d946bc32b
Contents?: true
Size: 583 Bytes
Versions: 6
Compression:
Stored size: 583 Bytes
Contents
require_relative '../../spec_helper' module Barometer::Query describe Format::ShortZipcode do describe '.geo' do specify { expect( Format::ShortZipcode.geo(nil) ).to eq({country_code: 'US'}) } specify { expect( Format::ShortZipcode.geo('ignored') ).to eq({country_code: 'US'}) } end describe '.is?' do it 'recognizes a valid format' do expect( Format::ShortZipcode.is?('90210') ).to be_true end it 'recognizes non-valid format' do expect( Format::ShortZipcode.is?('90210-5555') ).to be_false end end end end
Version data entries
6 entries across 6 versions & 1 rubygems