From e92f68e1b9c9a3ad93d30f6de234674f1acbe047 Mon Sep 17 00:00:00 2001 From: Andrew Date: Thu, 9 Aug 2018 02:55:49 -0700 Subject: [PATCH] Fixed flaky test --- test/order_test.rb | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/order_test.rb b/test/order_test.rb index 0a083b0..89b94a4 100644 --- a/test/order_test.rb +++ b/test/order_test.rb @@ -17,7 +17,7 @@ class OrderTest < Minitest::Test store_names ["Product A", "Product B"] product_a = Product.where(name: "Product A").first product_b = Product.where(name: "Product B").first - assert_order "product", [product_a, product_b].sort_by(&:id).map(&:name), order: {id: :asc} + assert_order "product", [product_a, product_b].sort_by { |r| r.id.to_s }.map(&:name), order: {id: :asc} end def test_order_multiple -- libgit2 0.21.0