module Selenium::WebDriver::Zipper
def unzip(path)
def unzip(path) destination = Dir.mktmpdir('webdriver-unzip') FileReaper << destination Zip::File.open(path) do |zip| zip.each do |entry| to = File.join(destination, entry.name) dirname = File.dirname(to) FileUtils.mkdir_p dirname unless File.exist? dirname zip.extract(entry, to) end end destination end