Sha256: 83ee7475325e6ce9b69aed3d631f7ab77595b2d59ba4e57079e5f3060be0db29

Contents?: true

Size: 466 Bytes

Versions: 18

Compression:

Stored size: 466 Bytes

Contents

require 'abstract_unit'

class TestEqual < ActiveSupport::TestCase
  fixtures :capitols

  def test_new
    assert_not_equal(Capitol.new, Capitol.new)
  end

  def test_same
    first = Capitol.find('Canada', 'Ottawa')
    second = Capitol.find('Canada', 'Ottawa')
    assert_equal(first, second)
  end

  def test_different
    first = Capitol.find('Mexico', 'Mexico City')
    second = Capitol.find('Canada', 'Ottawa')
    assert_not_equal(first, second)
  end
end

Version data entries

18 entries across 18 versions & 1 rubygems

Version Path
composite_primary_keys-3.1.11 test/test_equal.rb
composite_primary_keys-4.0.0.beta7 test/test_equal.rb
composite_primary_keys-4.0.0.beta6 test/test_equal.rb
composite_primary_keys-4.0.0.beta5 test/test_equal.rb
composite_primary_keys-4.0.0.beta4 test/test_equal.rb
composite_primary_keys-4.0.0.beta3 test/test_equal.rb
composite_primary_keys-3.1.10 test/test_equal.rb
composite_primary_keys-4.0.0.beta2 test/test_equal.rb
composite_primary_keys-4.0.0.beta1 test/test_equal.rb
composite_primary_keys-3.1.9 test/test_equal.rb
composite_primary_keys-3.1.8 test/test_equal.rb
composite_primary_keys-3.1.7 test/test_equal.rb
composite_primary_keys-3.1.6 test/test_equal.rb
composite_primary_keys-3.1.5 test/test_equal.rb
composite_primary_keys-3.1.4 test/test_equal.rb
composite_primary_keys-3.1.2 test/test_equal.rb
composite_primary_keys-3.1.1 test/test_equal.rb
composite_primary_keys-3.1.0 test/test_equal.rb