Module: BrowserTypes

Extended by:
BrowserTypes
Included in:
BrowserTypes
Defined in:
lib/applitools/selenium/browser_types.rb

Constant Summary collapse

CHROME =
:'chrome-0'
CHROME_ONE_VERSION_BACK =
:'chrome-1'
CHROME_TWO_VERSIONS_BACK =
:'chrome-2'
FIREFOX =
:'firefox-0'
FIREFOX_ONE_VERSION_BACK =
:'firefox-1'
FIREFOX_TWO_VERSIONS_BACK =
:'firefox-2'
SAFARI =
:'safari-0'
SAFARI_ONE_VERSION_BACK =
:'safari-1'
SAFARI_TWO_VERSIONS_BACK =
:'safari-2'
EDGE_CHROMIUM =
:'edgechromium'
EDGE_CHROMIUM_ONE_VERSION_BACK =
:'edgechromium-1'
IE_11 =
:ie
EDGE_LEGACY =
:edgelegacy
IE_10 =
:ie10

Instance Method Summary collapse

Instance Method Details

#const_defined?(name) ⇒ Boolean

Returns:

  • (Boolean)


23
24
25
26
# File 'lib/applitools/selenium/browser_types.rb', line 23

def const_defined?(name)
  return true if name == :EDGE
  super
end

#const_missing(name) ⇒ Object



28
29
30
31
32
33
34
35
36
37
38
# File 'lib/applitools/selenium/browser_types.rb', line 28

def const_missing(name)
  if name == :EDGE
    Applitools::EyesLogger.warn(
      'The \'EDGE\' option that is being used in your browsers\' configuration will soon be deprecated. ' \
      'Please change it to either \'EDGE_LEGACY\' for the legacy version ' \
      'or to \'EDGE_CHROMIUM\' for the new Chromium-based version.'
    )
    return EDGE_LEGACY
  end
  super
end

#enum_valuesObject



40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
# File 'lib/applitools/selenium/browser_types.rb', line 40

def enum_values
  [
    CHROME,
    CHROME_ONE_VERSION_BACK,
    CHROME_TWO_VERSIONS_BACK,
    FIREFOX,
    FIREFOX_ONE_VERSION_BACK,
    FIREFOX_TWO_VERSIONS_BACK,
    SAFARI,
    SAFARI_ONE_VERSION_BACK,
    SAFARI_TWO_VERSIONS_BACK,
    IE_11,
    EDGE_LEGACY,
    IE_10,
    EDGE_CHROMIUM,
    EDGE_CHROMIUM_ONE_VERSION_BACK
  ]
end