Sha256: 83c393fabad9795a7788ce746d0a310b5938e7b127fef391ad99e27071417e61

Contents?: true

Size: 430 Bytes

Versions: 10

Compression:

Stored size: 430 Bytes

Contents

require 'spec_helper'

describe "Waistband::Index - Type" do

  it "defaults to the first type we find in the mappings if possible" do
    index = Waistband::Index.new('events_no_name')
    expect(index.send(:default_type_name)).to eql 'event'
  end

  it "defaults to singular index name if no mappings" do
    index = Waistband::Index.new('no_mappings')
    expect(index.send(:default_type_name)).to eql 'no_mapping'
  end

end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
waistband-6.3.1 spec/lib/index/type_spec.rb
waistband-6.3.0 spec/lib/index/type_spec.rb
waistband-6.2.0 spec/lib/index/type_spec.rb
waistband-6.1.1 spec/lib/index/type_spec.rb
waistband-6.1.0 spec/lib/index/type_spec.rb
waistband-6.0.0 spec/lib/index/type_spec.rb
waistband-0.16.7 spec/lib/index/type_spec.rb
waistband-0.16.6 spec/lib/index/type_spec.rb
waistband-0.16.5 spec/lib/index/type_spec.rb
waistband-0.16.3 spec/lib/index/type_spec.rb