We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 703eb66 commit 0aa6b48Copy full SHA for 0aa6b48
spec/ajax-datatables-rails/orm/active_record_filter_records_spec.rb
@@ -358,10 +358,11 @@
358
it 'should filter records matching with multiple' do
359
datatable.params[:columns]['1'][:search][:value] = 'john@foo.com|henry@baz.com'
360
expect(datatable.data.size).to eq 2
361
- item_first = datatable.data.first
362
- item_last = datatable.data.last
363
- expect(item_first[:email]).to eq 'john@foo.com'
364
- expect(item_last[:email]).to eq 'henry@baz.com'
+ items = datatable.data.sort_by { |h| h[:email] }
+ item_first = items.first
+ item_last = items.last
+ expect(item_first[:email]).to eq 'henry@baz.com'
365
+ expect(item_last[:email]).to eq 'john@foo.com'
366
end
367
368
it 'should filter records matching with multiple contains not found' do
0 commit comments