Sha256: 664bafca93f5741427ddb7293928669e0a9788c309f5563a2e197227e73383eb
Contents?: true
Size: 488 Bytes
Versions: 19
Compression:
Stored size: 488 Bytes
Contents
module Watir module Atoms ATOMS = {} def self.load(function_name) ATOMS[function_name] = File.read(File.expand_path("../atoms/#{function_name}.js", __FILE__)) end load :fireEvent load :getAttribute load :getOuterHtml load :getParentElement private def execute_atom(function_name, *arguments) script = "return (%s).apply(null, arguments)" % ATOMS.fetch(function_name) driver.execute_script(script, *arguments) end end end
Version data entries
19 entries across 19 versions & 1 rubygems