blob: 19a554ce42581d4fd524e7a3f644e7d4e43f40bc (
plain) (
blame)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
|
require 'helper'
module Arel
module Visitors
class TestDot < MiniTest::Unit::TestCase
def setup
@visitor = Visitors::Dot.new
end
# unary ops
[
Arel::Nodes::Not,
Arel::Nodes::Group,
Arel::Nodes::On,
Arel::Nodes::Grouping,
Arel::Nodes::Offset,
Arel::Nodes::Having,
Arel::Nodes::UnqualifiedColumn,
].each do |klass|
define_method("test_#{klass.name.gsub('::', '_')}") do
op = klass.new(:a)
@visitor.accept op
end
end
end
end
end
|