Sha256: 8a0c4579a3cdc715cd21230c675ec0a3e54e667eb7fb788bea8c0a63a3f3a4e6

Contents?: true

Size: 448 Bytes

Versions: 13

Compression:

Stored size: 448 Bytes

Contents

require 'spec_helper'
require 'active_record/turntable/sql_tree_patch'

describe SQLTree do
  before(:all) do
    reload_turntable!(File.join(File.dirname(__FILE__), "../../config/turntable.yml"))
  end

  context "Insert query with binary string" do
    subject { SQLTree["INSERT INTO `hogehoge` (`name`) VALUES (x'deadbeef')"] }
    it { expect { subject }.to_not raise_error }
    its(:to_sql) { is_expected.to include("x'deadbeef") }
  end
end

Version data entries

13 entries across 13 versions & 1 rubygems

Version Path
activerecord-turntable-2.2.2 spec/active_record/turntable/sql_tree_patch_spec.rb
activerecord-turntable-2.2.1 spec/active_record/turntable/sql_tree_patch_spec.rb
activerecord-turntable-2.2.0 spec/active_record/turntable/sql_tree_patch_spec.rb
activerecord-turntable-2.1.1 spec/active_record/turntable/sql_tree_patch_spec.rb
activerecord-turntable-2.1.0 spec/active_record/turntable/sql_tree_patch_spec.rb
activerecord-turntable-2.1.0.rc2 spec/active_record/turntable/sql_tree_patch_spec.rb
activerecord-turntable-2.1.0.rc1 spec/active_record/turntable/sql_tree_patch_spec.rb
activerecord-turntable-2.1.0.beta2 spec/active_record/turntable/sql_tree_patch_spec.rb
activerecord-turntable-2.1.0.beta1 spec/active_record/turntable/sql_tree_patch_spec.rb
activerecord-turntable-2.0.6 spec/active_record/turntable/sql_tree_patch_spec.rb
activerecord-turntable-2.0.5 spec/active_record/turntable/sql_tree_patch_spec.rb
activerecord-turntable-2.0.4 spec/active_record/turntable/sql_tree_patch_spec.rb
activerecord-turntable-2.0.3 spec/active_record/turntable/sql_tree_patch_spec.rb