Sha256: 11e8a776abd6a7828b7ff8ef21ddc27d83512148451dd0aaf52b9d3ce15668c7

Contents?: true

Size: 1.02 KB

Versions: 34

Compression:

Stored size: 1.02 KB

Contents

require 'flydata/fluent-plugins/flydata_plugin_ext/flydata_sync_shared_examples'


module Fluent

shared_examples 'flydata sync diff based shared examples' do
  include_examples 'flydata sync shared examples'

  describe '#configure' do
    let(:config) do
      c = default_config
      c = replace_conf(c, 'tables', 'table_1')
      c = replace_conf(c, 'fetch_interval', '10m')
      c = replace_conf(c, 'retry_interval', '5m')
      c = replace_conf(c, 'emit_chunk_limit', '32m')
      c
    end

    subject { Test.configure_plugin(plugin, config) }

    before do
      create_table_pos_file('table_1')
      subject
    end

    it { expect(config_value(:@fetch_interval)).to eq(10 * 60) }
    it { expect(config_value(:@retry_interval)).to eq(5 * 60) }
    it { expect(config_value(:@emit_chunk_limit)).to eq(32 * 1024**2) }
    it do
      expect(config_value(:@table_src_pos_files).size).to eq(1)
      expect(config_value(:@table_src_pos_files)[:table_1]).to be_kind_of(described_class::SOURCE_POSITION_FILE_CLASS)
    end
  end
end

end

Version data entries

34 entries across 34 versions & 1 rubygems

Version Path
flydata-0.8.10.2 spec/flydata/fluent-plugins/flydata_plugin_ext/flydata_sync_diff_based_shared_examples.rb
flydata-0.8.10.1 spec/flydata/fluent-plugins/flydata_plugin_ext/flydata_sync_diff_based_shared_examples.rb
flydata-0.8.9.11 spec/flydata/fluent-plugins/flydata_plugin_ext/flydata_sync_diff_based_shared_examples.rb
flydata-0.8.10 spec/flydata/fluent-plugins/flydata_plugin_ext/flydata_sync_diff_based_shared_examples.rb
flydata-0.8.9 spec/flydata/fluent-plugins/flydata_plugin_ext/flydata_sync_diff_based_shared_examples.rb
flydata-0.8.8 spec/flydata/fluent-plugins/flydata_plugin_ext/flydata_sync_diff_based_shared_examples.rb
flydata-0.8.7 spec/flydata/fluent-plugins/flydata_plugin_ext/flydata_sync_diff_based_shared_examples.rb
flydata-0.8.6 spec/flydata/fluent-plugins/flydata_plugin_ext/flydata_sync_diff_based_shared_examples.rb
flydata-0.8.5 spec/flydata/fluent-plugins/flydata_plugin_ext/flydata_sync_diff_based_shared_examples.rb
flydata-0.8.4 spec/flydata/fluent-plugins/flydata_plugin_ext/flydata_sync_diff_based_shared_examples.rb
flydata-0.8.3 spec/flydata/fluent-plugins/flydata_plugin_ext/flydata_sync_diff_based_shared_examples.rb
flydata-0.8.2 spec/flydata/fluent-plugins/flydata_plugin_ext/flydata_sync_diff_based_shared_examples.rb
flydata-0.8.1 spec/flydata/fluent-plugins/flydata_plugin_ext/flydata_sync_diff_based_shared_examples.rb
flydata-0.8.0 spec/flydata/fluent-plugins/flydata_plugin_ext/flydata_sync_diff_based_shared_examples.rb
flydata-0.7.19 spec/flydata/fluent-plugins/flydata_plugin_ext/flydata_sync_diff_based_shared_examples.rb
flydata-0.7.18 spec/flydata/fluent-plugins/flydata_plugin_ext/flydata_sync_diff_based_shared_examples.rb
flydata-0.7.17 spec/flydata/fluent-plugins/flydata_plugin_ext/flydata_sync_diff_based_shared_examples.rb
flydata-0.7.16 spec/flydata/fluent-plugins/flydata_plugin_ext/flydata_sync_diff_based_shared_examples.rb
flydata-0.7.15 spec/flydata/fluent-plugins/flydata_plugin_ext/flydata_sync_diff_based_shared_examples.rb
flydata-0.7.14 spec/flydata/fluent-plugins/flydata_plugin_ext/flydata_sync_diff_based_shared_examples.rb