Sha256: 80bca78462ca9c49066fe231b0cec619cdf7f6efaae81c5d2b99ad4393ce16c4

Contents?: true

Size: 608 Bytes

Versions: 113

Compression:

Stored size: 608 Bytes

Contents

require 'helper'

module Arel
  module Nodes
    class TestBin < MiniTest::Unit::TestCase
      def test_new
        assert Arel::Nodes::Bin.new('zomg')
      end

      def test_default_to_sql
        viz  = Arel::Visitors::ToSql.new Table.engine.connection_pool
        node = Arel::Nodes::Bin.new(Arel.sql('zomg'))
        assert_equal 'zomg', viz.accept(node)
      end

      def test_mysql_to_sql
        viz  = Arel::Visitors::MySQL.new Table.engine.connection_pool
        node = Arel::Nodes::Bin.new(Arel.sql('zomg'))
        assert_equal 'BINARY zomg', viz.accept(node)
      end
    end
  end
end

Version data entries

113 entries across 95 versions & 14 rubygems

Version Path
dirty_history-0.5.2 dirty_history/ruby/1.9.1/gems/arel-2.2.1/test/nodes/test_bin.rb
challah-0.5.1 vendor/bundle/gems/arel-3.0.2/test/nodes/test_bin.rb
arel-3.0.2 test/nodes/test_bin.rb
arel-2.2.3 test/nodes/test_bin.rb
arel-3.0.1 test/nodes/test_bin.rb
arel-2.2.2 test/nodes/test_bin.rb
challah-0.5.0 vendor/bundle/gems/arel-3.0.0/test/nodes/test_bin.rb
dirty_history-0.5.1 dirty_history/ruby/1.9.1/gems/arel-2.2.1/test/nodes/test_bin.rb
dirty_history-0.5.0 dirty_history/ruby/1.9.1/gems/arel-2.2.1/test/nodes/test_bin.rb
challah-0.4.1 vendor/bundle/gems/arel-3.0.0/test/nodes/test_bin.rb
challah-0.4.0 vendor/bundle/gems/arel-3.0.0/test/nodes/test_bin.rb
challah-0.3.5 vendor/bundle/gems/arel-3.0.0/test/nodes/test_bin.rb
challah-0.3.4 vendor/bundle/gems/arel-3.0.0/test/nodes/test_bin.rb
challah-0.3.3 vendor/bundle/gems/arel-3.0.0/test/nodes/test_bin.rb
challah-0.3.2 vendor/bundle/gems/arel-3.0.0/test/nodes/test_bin.rb
challah-0.3.1 vendor/bundle/gems/arel-3.0.0/test/nodes/test_bin.rb
challah-0.3.0 vendor/bundle/gems/arel-3.0.0/test/nodes/test_bin.rb
challah-0.2.1 vendor/bundle/gems/arel-3.0.0/test/nodes/test_bin.rb
challah-0.2.0 vendor/bundle/gems/arel-3.0.0/test/nodes/test_bin.rb
arel-3.0.0 test/nodes/test_bin.rb