Sha256: 767c371d8ab8ed0c11ec4a14bbe20f8717797c71be159b045958acf1219fe6ec

Contents?: true

Size: 363 Bytes

Versions: 4

Compression:

Stored size: 363 Bytes

Contents

require 'spec_helper'

describe Hash do
  context 'select_keys' do
    it 'debería tomar los values de las keys indicadas' do
      hash = Hash[1, 2, 3, 4]
      hash.select_keys(1).should == {1 => 2}
      hash.select_keys(1, 3).should == {1 => 2, 3 => 4}
      hash.select_keys(5).should == {}
      hash.select_keys(5, 3).should == {3 => 4}
    end
  end
end

Version data entries

4 entries across 4 versions & 1 rubygems

Version Path
afipws-2.3.0 spec/afipws/core_ext/hash_spec.rb
afipws-2.2.0 spec/afipws/core_ext/hash_spec.rb
afipws-2.1.0 spec/afipws/core_ext/hash_spec.rb
afipws-2.0.0 spec/afipws/core_ext/hash_spec.rb