未验证 提交 b4bca947 编写于 作者: R Ryuta Kamizono 提交者: GitHub

Merge pull request #39023 from kamipo/remove_unused_operand1_operand2

Remove unused `operand1`/`operand2` aliases
......@@ -4,8 +4,6 @@ module Arel # :nodoc: all
module Nodes
class Equality < Arel::Nodes::Binary
def operator; :== end
alias :operand1 :left
alias :operand2 :right
def invert
Arel::Nodes::NotEqual.new(left, right)
......
......@@ -15,22 +15,6 @@ module Nodes
end
end
describe "operand1" do
it "should equal left" do
attr = Table.new(:users)[:id]
left = attr.eq(10)
_(left.left).must_equal left.operand1
end
end
describe "operand2" do
it "should equal right" do
attr = Table.new(:users)[:id]
left = attr.eq(10)
_(left.right).must_equal left.operand2
end
end
describe "to_sql" do
it "takes an engine" do
engine = FakeRecord::Base.new
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册