diff --git a/activerecord/test/cases/adapters/mysql/quoting_test.rb b/activerecord/test/cases/adapters/mysql/quoting_test.rb index ca476947fc..426b088e2f 100644 --- a/activerecord/test/cases/adapters/mysql/quoting_test.rb +++ b/activerecord/test/cases/adapters/mysql/quoting_test.rb @@ -15,14 +15,14 @@ class MysqlQuotingTest < ActiveRecord::MysqlTestCase def test_quoted_date_precision_for_gte_564 @conn.stubs(:full_version).returns('5.6.4') - @conn.remove_instance_variable(:@version) + @conn.remove_instance_variable(:@version) if @conn.instance_variable_defined?(:@version) t = Time.now.change(usec: 1) assert_match(/\.000001\z/, @conn.quoted_date(t)) end def test_quoted_date_precision_for_lt_564 @conn.stubs(:full_version).returns('5.6.3') - @conn.remove_instance_variable(:@version) + @conn.remove_instance_variable(:@version) if @conn.instance_variable_defined?(:@version) t = Time.now.change(usec: 1) refute_match(/\.000001\z/, @conn.quoted_date(t)) end