Sha256: 3d5197feff83010484b5b38a81a2eefd975a4c32d81b839cf08ec2d82cd16c89

Contents?: true

Size: 318 Bytes

Versions: 28

Compression:

Stored size: 318 Bytes

Contents

require_relative 'helper'
require 'swift/identity_map'

describe 'IdentityMap' do
  before do
    @im = Swift::IdentityMap.new
  end

  it %q{returns nil on GC'd object} do
    2.times do
      @im.set('foo', 'foo')
      assert_equal 'foo', @im.get('foo')
    end
    GC.start
    assert_nil @im.get('foo')
  end
end

Version data entries

28 entries across 28 versions & 1 rubygems

Version Path
swift-1.2.3 test/test_identity_map.rb
swift-1.2.2 test/test_identity_map.rb
swift-1.2.1 test/test_identity_map.rb
swift-1.2.0 test/test_identity_map.rb
swift-1.1.0 test/test_identity_map.rb
swift-1.0.3 test/test_identity_map.rb
swift-1.0.2 test/test_identity_map.rb
swift-1.0.1 test/test_identity_map.rb
swift-1.0.0 test/test_identity_map.rb
swift-0.14.0 test/test_identity_map.rb
swift-0.13.0 test/test_identity_map.rb
swift-0.12.0 test/test_identity_map.rb
swift-0.11.0 test/test_identity_map.rb
swift-0.10.0 test/test_identity_map.rb
swift-0.9.1 test/test_identity_map.rb
swift-0.9.0 test/test_identity_map.rb
swift-0.8.1 test/test_identity_map.rb
swift-0.8.0 test/test_identity_map.rb
swift-0.7.2 test/test_identity_map.rb
swift-0.7.1 test/test_identity_map.rb