test/highlight_test.rb in searchkick-0.9.1 vs test/highlight_test.rb in searchkick-1.0.0

- old
+ new

@@ -1,9 +1,8 @@ require_relative "test_helper" -class TestHighlight < Minitest::Test - +class HighlightTest < Minitest::Test def test_basic store_names ["Two Door Cinema Club"] assert_equal "Two Door <em>Cinema</em> Club", Product.search("cinema", fields: [:name], highlight: true).with_details.first[1][:highlight][:name] end @@ -39,11 +38,11 @@ def test_json store_names ["Two Door Cinema Club"] json = { query: { match: { - _all: "cinema" + "name.analyzed" => "cinema" } }, highlight: { pre_tags: ["<strong>"], post_tags: ["</strong>"], @@ -52,7 +51,6 @@ } } } assert_equal "Two Door <strong>Cinema</strong> Club", Product.search(json: json).with_details.first[1][:highlight][:"name.analyzed"] end - end