22

Watir screenshot taker with

http://feeds.dzone.com

// description of your code here

# for WATIR scripts by marekj testr.us
module TestRun

# TestRun.record(__FILE__,{:1, 'Bacon', :2, 'Apple', :3, 'Cheese'})
#
# writes or appends a yaml doc to file named filename as the file that invoked the method
# ---
# :1: Bacon
# :2: Apple
# :3: Cheese
#
# example: if __FILE__ is c:\foofoo\away\in\windowz\land\scirptname.rb then
# creates 'logs' subdir (if it doesn't exist) and appends (or writes a new yaml file)
# c:\foofoo\away\in\windowz\land\logs\scirptname.yaml
#
# Dump yaml doc with no particular structure. it can be hash of hashes, array of arrays or
# whatever you collect during the run. We want an automatic persistence of data and a history of
# script execution.
def self.record(scriptFile,run_record)
$log.debug("Recording: #{run_record.inspect}")
script_logpath = File.join(File.dirname(scriptFile),'logs')
script_log = File.join(script_logpath,File.basename(scriptFile,'.rb')

Read »
Created by toxic Created 37 weeks 2 days ago – Made popular 37 weeks 2 days ago
Category: Programming   Tags: