grep returns an array with 0 or more results, we can use
ActiveRecord::Base.connection.instance_values["config"][:adapter].grep(/mysql/).any?