Sha256: ed5bd5acf8de405ed3ae058c4d89121d3dac6513235607fa9180f12722f0a2cf

Contents?: true

Size: 340 Bytes

Versions: 8

Compression:

Stored size: 340 Bytes

Contents

require 'helper'

describe 'find_in_batches' do
  after do
    Post.destroy_all
  end

  it 'accepts finder options' do
    foo = Post.create title: 'foo'
    Post.create title: 'bar'

    assert_deprecated do
      Post.find_in_batches(conditions: "title = 'foo'") do |records|
        records.must_equal [foo]
      end
    end
  end
end

Version data entries

8 entries across 8 versions & 2 rubygems

Version Path
challah-1.0.0 vendor/bundle/gems/activerecord-deprecated_finders-1.0.3/test/find_in_batches_test.rb
activerecord-deprecated_finders-1.0.3 test/find_in_batches_test.rb
activerecord-deprecated_finders-1.0.2 test/find_in_batches_test.rb
activerecord-deprecated_finders-1.0.1 test/find_in_batches_test.rb
activerecord-deprecated_finders-1.0.0 test/find_in_batches_test.rb
activerecord-deprecated_finders-0.0.3 test/find_in_batches_test.rb
activerecord-deprecated_finders-0.0.2 test/find_in_batches_test.rb
activerecord-deprecated_finders-0.0.1 test/find_in_batches_test.rb