class RuboCop::Cop::Style::CaseLikeIf

def condition_from_binary_op(lhs, rhs, target)

def condition_from_binary_op(lhs, rhs, target)
  lhs = deparenthesize(lhs)
  rhs = deparenthesize(rhs)
  if lhs == target
    rhs
  elsif rhs == target
    lhs
  end
end