Sha256: b7e261c69194faeccffc809eed3ff1598dbdb91824442ffa0fc5e774553c0039

Contents?: true

Size: 638 Bytes

Versions: 2

Compression:

Stored size: 638 Bytes

Contents

begin
  require 'rspec/expectations'
rescue LoadError
  require 'spec/expectations'
end

browser = nil

if ENV['FIREFOX']
  require 'watir-webdriver'
  Browser = Watir::Browser
  browser = Browser.new :ff
else
  case RUBY_PLATFORM
  when /darwin/
    require 'safariwatir'
    Browser = Watir::Safari
  when /win32|mingw/
    require 'watir'
    Browser = Watir::IE
  when /java/
    require 'celerity'
    Browser = Celerity::Browser
  else
    raise "This platform is not supported (#{RUBY_PLATFORM})"
  end

  # "before all"
  browser = Browser.new
end

Before do
  @browser = browser
end

# "after all"
at_exit do
  browser.close
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
cucumber-3.0.1 examples/watir/features/support/env.rb
cucumber-3.0.0 examples/watir/features/support/env.rb