class RuboCop::Cop::Sorbet::ForbidIncludeConstLiteral

def within_onymous_module?(node)

Returns true if the node is within a module declaration that is not anonymous.
def within_onymous_module?(node)
  parent = node.parent
  parent = parent.parent while parent&.type?(:begin, :block)
  parent&.type?(:module, :class, :sclass)
end