From dd0b083645bdbe7ecbeee106db1bc34852fe40d2 Mon Sep 17 00:00:00 2001 From: Andrew Kane Date: Sun, 8 Jan 2017 18:42:10 -0800 Subject: [PATCH] Fixed test --- Rakefile | 1 + test/index_test.rb | 6 +++--- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/Rakefile b/Rakefile index 4c91830..93c1699 100644 --- a/Rakefile +++ b/Rakefile @@ -5,6 +5,7 @@ task default: :test Rake::TestTask.new do |t| t.libs << "test" t.pattern = "test/**/*_test.rb" + t.warning = false end task :benchmark do diff --git a/test/index_test.rb b/test/index_test.rb index 38884d0..4d62708 100644 --- a/test/index_test.rb +++ b/test/index_test.rb @@ -114,10 +114,10 @@ class IndexTest < Minitest::Test store_names ["Product A"] raise ActiveRecord::Rollback end - assert_search "product", [] + assert_search "*", [] end - def test_analyzed_only + def test_filterable # skip for 5.0 since it throws # Cannot search on field [alt_description] since it is not indexed. skip unless elasticsearch_below50? @@ -125,7 +125,7 @@ class IndexTest < Minitest::Test assert_search "*", [], where: {alt_description: "Hello"} end - def test_analyzed_only_large_value + def test_large_value skip if nobrainer? large_value = 10000.times.map { "hello" }.join(" ") store [{name: "Product A", alt_description: large_value}] -- libgit2 0.21.0