spec/ziptz_spec.rb in ziptz-1.1.37 vs spec/ziptz_spec.rb in ziptz-2.0.0

- old
+ new

@@ -12,11 +12,11 @@ describe '#time_zone_name' do let(:ziptz) { Ziptz.new } context 'when given a 5-digit zipcode' do it 'returns the time zone number' do - expect(ziptz.time_zone_name('97034')).to eq 'Pacific' + expect(ziptz.time_zone_name('97034')).to eq 'America/Los_Angeles' end end context 'when there is no matching zipcode' do it 'returns nil' do @@ -28,11 +28,11 @@ describe '#time_zone_uses_dst?' do let(:ziptz) { Ziptz.new } context 'when given a 5-digit zipcode' do it 'returns the time zone number' do - expect(ziptz.time_zone_name('97034')).to eq 'Pacific' + expect(ziptz.time_zone_name('97034')).to eq 'America/Los_Angeles' end end end describe '#time_zone_offset' do @@ -55,14 +55,14 @@ describe '#zips' do context 'when given a time zone' do let(:ziptz) { Ziptz.new } it 'returns an array of zip codes' do - expect(ziptz.zips('American Samoa')).to eq %w(96799) + expect(ziptz.zips('Pacific/Pago_Pago')).to eq %w(96799) end it 'is case-insensitive' do - expect(ziptz.zips('american samoa')).to eq %w(96799) + expect(ziptz.zips('Pacific/Pago_Pago')).to eq %w(96799) end it 'returns nil for unknown time zones' do expect(ziptz.zips('Glark')).to be_nil end