Sha256: 53c91706c12683c237e68b6c3bd6bfd26c65599455fcfb5da385f6ac17b9dc70

Contents?: true

Size: 791 Bytes

Versions: 2

Compression:

Stored size: 791 Bytes

Contents

module OperaWatir
  
  module Compat; end

  # Switches on compatibility layer (Watir 1 API).
  def self.compatibility!
    # require 'operawatir/compat/deprecation'
    require 'operawatir/compat/browser'
    require 'operawatir/compat/element_finders'
    require 'operawatir/compat/window'
    
    Browser.send :include, Compat::Browser
    Window.send :include, Compat::ElementFinders
    Window.send :include, Compat::Window
    Collection.send :include, Compat::ElementFinders
    
    # TODO Ruby Modules can't override methods defined in their included klass
    #   Requiring the files is OK, but there needs to be some way of detecting
    #   that we are in compatibility mode.
    
    require 'operawatir/compat/collection'
    require 'operawatir/compat/element'
  end
  
end

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
operawatir-0.3.2-jruby lib/operawatir/compat.rb
operawatir-0.3-jruby lib/operawatir/compat.rb