Sha256: 6e75edd869af5a734dd49a9e44d6d9e020f3caf223cf9543e69aef0ecb66a30d

Contents?: true

Size: 607 Bytes

Versions: 2

Compression:

Stored size: 607 Bytes

Contents

require File.expand_path(File.join(File.dirname(__FILE__), 'test_helper'))

class VersionedTest < Test::Unit::TestCase
  context 'ActiveRecord models' do
    should 'respond to the "versioned?" method' do
      assert ActiveRecord::Base.respond_to?(:versioned?)
      assert User.respond_to?(:versioned?)
    end

    should 'return true for the "versioned?" method if the model is versioned' do
      assert_equal true, User.versioned?
    end

    should 'return false for the "versioned?" method if the model is not versioned' do
      assert_equal false, ActiveRecord::Base.versioned?
    end
  end
end

Version data entries

2 entries across 2 versions & 2 rubygems

Version Path
bitfluent-vestal_versions-1.1.0 test/versioned_test.rb
brianjlandau-vestal_versions-1.3.0 test/versioned_test.rb