class ScreenCapture

Public Class Methods

capture(url, file, width=1024, height=800) click to toggle source
# File lib/screen_capture.rb, line 2
def self.capture(url, file, width=1024, height=800)
  command = "phantomjs #{File.expand_path(File.dirname(__FILE__)+'/..')}/src/screen_capture.js #{url} #{file} #{width} #{height}"
  puts "Executing: #{command}"
  value = `#{command}`
  puts "Command: #{value}"
end