module Selenium::WebDriver::Atoms
Public Instance Methods
atom_script(function_name)
click to toggle source
# File lib/selenium/webdriver/atoms.rb, line 23 def atom_script(function_name) format("/* #{function_name} */return (%<atom>s).apply(null, arguments)", atom: read_atom(function_name)) end
Private Instance Methods
execute_atom(function_name, *arguments)
click to toggle source
# File lib/selenium/webdriver/atoms.rb, line 34 def execute_atom(function_name, *arguments) execute_script(atom_script(function_name), *arguments) end
read_atom(function)
click to toggle source
# File lib/selenium/webdriver/atoms.rb, line 30 def read_atom(function) File.read(File.expand_path("../atoms/#{function}.js", __FILE__)) end