Permalink
Browse files

Include mysql older than 5.1.23 in the 5.1 series in the list of thos…

…e that can't handle NULL defaults

Signed-off-by: Jeremy Kemper <jeremy@bitsweat.net>
  • Loading branch information...
1 parent 52e15ab commit fa795ccfade59c4bbab91ada3bb34e5fbfac448c @tarmo tarmo committed with jeremy Aug 26, 2008
Showing with 1 addition and 1 deletion.
  1. +1 −1 activerecord/test/cases/defaults_test.rb
@@ -5,7 +5,7 @@
class DefaultTest < ActiveRecord::TestCase
def test_nil_defaults_for_not_null_columns
column_defaults =
- if current_adapter?(:MysqlAdapter) && Mysql.client_version < 50051
+ if current_adapter?(:MysqlAdapter) && (Mysql.client_version < 50051 || (50100..50122).include?(Mysql.client_version))
{ 'id' => nil, 'name' => '', 'course_id' => nil }
else
{ 'id' => nil, 'name' => nil, 'course_id' => nil }

0 comments on commit fa795cc

Please sign in to comment.