Sha256: 3029b6199d599ffe3004e9f80a8162d3b2c91f4e3cdb610a0d456699d87b42c3

Contents?: true

Size: 479 Bytes

Versions: 7

Compression:

Stored size: 479 Bytes

Contents

require 'spec_helper'

describe AjaxDatatablesRails::Datatable::SimpleSearch do

  let(:options) { ActiveSupport::HashWithIndifferentAccess.new({'value' => 'search value', 'regex' => 'true'}) }
  let(:simple_search) { AjaxDatatablesRails::Datatable::SimpleSearch.new(options) }

  describe 'option methods' do
    it 'regexp?' do
      expect(simple_search.regexp?).to be(true)
    end

    it 'value' do
      expect(simple_search.value).to eq('search value')
    end
  end
end

Version data entries

7 entries across 7 versions & 1 rubygems

Version Path
ajax-datatables-rails-1.3.0 spec/ajax-datatables-rails/datatable/simple_search_spec.rb
ajax-datatables-rails-1.2.0 spec/ajax-datatables-rails/datatable/simple_search_spec.rb
ajax-datatables-rails-1.1.0 spec/ajax-datatables-rails/datatable/simple_search_spec.rb
ajax-datatables-rails-1.0.0 spec/ajax-datatables-rails/datatable/simple_search_spec.rb
ajax-datatables-rails-0.4.3 spec/ajax-datatables-rails/datatable/simple_search_spec.rb
ajax-datatables-rails-0.4.2 spec/ajax-datatables-rails/datatable/simple_search_spec.rb
ajax-datatables-rails-0.4.1 spec/ajax-datatables-rails/datatable/simple_search_spec.rb