Sha256: b91cf937ab346a85a4e52f4f33da7540fa77865657ec01e4dfb89e6d090317f6
Contents?: true
Size: 791 Bytes
Versions: 5
Compression:
Stored size: 791 Bytes
Contents
require 'mixology' module PageObject module Elements class Image < Element def initialize(element, platform) @element = element include_platform_for platform end protected def include_platform_for platform super if platform[:platform] == :watir_webdriver require 'page-object/platforms/watir_webdriver/image' self.mixin PageObject::Platforms::WatirWebDriver::Image elsif platform[:platform] == :selenium_webdriver require 'page-object/platforms/selenium_webdriver/image' self.mixin PageObject::Platforms::SeleniumWebDriver::Image else raise ArgumentError, "expect platform to be :watir_webdriver or :selenium_webdriver" end end end end end
Version data entries
5 entries across 5 versions & 1 rubygems