Skip to content

Commit

Permalink
Merge pull request #27621 from dylanahsmith/mysql2-nil-connection-test
Browse files Browse the repository at this point in the history
activerecord/test: Fix Mysql2ConnectionTest#test_execute_after_disconnect
  • Loading branch information
senny committed Jan 10, 2017
2 parents 6be3945 + a01a3fa commit a8a97f7
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion activerecord/test/cases/adapters/mysql2/connection_test.rb
Expand Up @@ -66,9 +66,10 @@ def test_successful_reconnection_after_timeout_with_verify
def test_execute_after_disconnect
@connection.disconnect!

assert_raise(ActiveRecord::StatementInvalid) do
error = assert_raise(ActiveRecord::StatementInvalid) do
@connection.execute("SELECT 1")
end
assert_kind_of Mysql2::Error, error.cause
end

def test_quote_after_disconnect
Expand Down

0 comments on commit a8a97f7

Please sign in to comment.