Permalink
Browse files

Skip binary data with binds test for mysql2, fix build

Mysql2 doesn't support binds, which means no binds payload is set when
logging, so the logic to render binary data differently here doesn't work.

Introduced in 99d142a.
  • Loading branch information...
1 parent df9f9b7 commit f447240b0565fa48f0dbe9341a7bb0feff938dab @carlosantoniodasilva carlosantoniodasilva committed Dec 14, 2012
@@ -1,7 +1,7 @@
module ActiveRecord
class LogSubscriber < ActiveSupport::LogSubscriber
IGNORE_PAYLOAD_NAMES = ["SCHEMA", "EXPLAIN"]
-
+
def self.runtime=(value)
Thread.current[:active_record_sql_runtime] = value
end
@@ -103,6 +103,8 @@ def test_initializes_runtime
end
def test_binary_data_is_not_logged
+ skip if current_adapter?(:Mysql2Adapter)
+
Binary.create(:data => 'some binary data')
wait
assert_equal 3, @logger.logged(:debug).size

0 comments on commit f447240

Please sign in to comment.