Sha256: 77343990c508bfa43b8fbffa3f5899776d8b8a92da00151d70c7939c5894f7cd

Contents?: true

Size: 770 Bytes

Versions: 10

Compression:

Stored size: 770 Bytes

Contents

module OperaWatir

  module Compat; end

  # Switches on compatibility layer (Watir 2 API).
  def self.compatibility!
    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/selector'
    require 'operawatir/compat/collection'
    require 'operawatir/compat/element'
  end

end

Version data entries

10 entries across 10 versions & 1 rubygems

Version Path
operawatir-0.7.pre4-jruby lib/operawatir/compat.rb
operawatir-0.7.pre3-jruby lib/operawatir/compat.rb
operawatir-0.7.pre2-jruby lib/operawatir/compat.rb
operawatir-0.7.pre1-jruby lib/operawatir/compat.rb
operawatir-0.6.pre1-jruby lib/operawatir/compat.rb
operawatir-0.5.1-jruby lib/operawatir/compat.rb
operawatir-0.5-jruby lib/operawatir/compat.rb
operawatir-0.5.pre3-jruby lib/operawatir/compat.rb
operawatir-0.5.pre2-jruby lib/operawatir/compat.rb
operawatir-0.5.pre1-jruby lib/operawatir/compat.rb