diff --git a/test/load_test.rb b/test/load_test.rb index b45bd13..db2955a 100644 --- a/test/load_test.rb +++ b/test/load_test.rb @@ -1,27 +1,27 @@ require_relative "test_helper" class LoadTest < Minitest::Test - def test_load_default + def test_default store_names ["Product A"] assert_kind_of Product, Product.search("product").first end - def test_load_false + def test_false store_names ["Product A"] - assert_kind_of Hash, Product.search("product", load: false).first + assert_kind_of Searchkick::HashWrapper, Product.search("product", load: false).first end - def test_load_false_methods + def test_false_methods store_names ["Product A"] assert_equal "Product A", Product.search("product", load: false).first.name end - def test_load_false_with_includes + def test_false_with_includes store_names ["Product A"] - assert_kind_of Hash, Product.search("product", load: false, includes: [:store]).first + assert_kind_of Searchkick::HashWrapper, Product.search("product", load: false, includes: [:store]).first end - def test_load_false_nested_object + def test_false_nested_object aisle = {"id" => 1, "name" => "Frozen"} store [{name: "Product A", aisle: aisle}] assert_equal aisle, Product.search("product", load: false).first.aisle.to_hash -- libgit2 0.21.0