From 7589e9081468e25e67745f241c0b36116adbd7fa Mon Sep 17 00:00:00 2001 From: Aidan Haran Date: Wed, 15 Apr 2020 14:27:56 +0100 Subject: [PATCH] Fix showplan test --- test/cases/showplan_test_sqlserver.rb | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/test/cases/showplan_test_sqlserver.rb b/test/cases/showplan_test_sqlserver.rb index 848f6f151..f54a37a88 100644 --- a/test/cases/showplan_test_sqlserver.rb +++ b/test/cases/showplan_test_sqlserver.rb @@ -21,14 +21,14 @@ class ShowplanTestSQLServer < ActiveRecord::TestCase it 'from prepared statement' do plan = Car.where(name: ',').limit(1).explain - _(plan).must_include " SELECT [cars].* FROM [cars] WHERE [cars].[name]" + _(plan).must_include "SELECT [cars].* FROM [cars] WHERE [cars].[name]" _(plan).must_include "TOP EXPRESSION", 'make sure we do not showplan the sp_executesql' _(plan).must_include "Clustered Index Scan", 'make sure we do not showplan the sp_executesql' end it 'from array condition using index' do plan = Car.where(id: [1, 2]).explain - _(plan).must_include " SELECT [cars].* FROM [cars] WHERE [cars].[id] IN (1, 2)" + _(plan).must_include "SELECT [cars].* FROM [cars] WHERE [cars].[id] IN (1, 2)" _(plan).must_include "Clustered Index Seek", 'make sure we do not showplan the sp_executesql' end