class Nokogiri::XML::NodeSet

def wrap(html, &blk)

Wrap this NodeSet with +html+ or the results of the builder in +blk+
##
def wrap(html, &blk)
  each do |j|
    new_parent = Nokogiri.make(html, &blk)
    j.replace(new_parent)
    nest = new_parent
    if nest.child
      nest = nest.child until nest.child.nil?
    end
    j.parent = nest
  end
  self
end