Exception: TestaAppiumDriver::StrategyMixException

Inherits:
Exception
  • Object
show all
Defined in:
lib/testa_appium_driver/common/exceptions/strategy_mix_exception.rb

Instance Method Summary collapse

Constructor Details

#initialize(strategy, strategy_reason, mixed_strategy, mixed_reason) ⇒ StrategyMixException

Returns a new instance of StrategyMixException.



5
6
7
8
9
10
# File 'lib/testa_appium_driver/common/exceptions/strategy_mix_exception.rb', line 5

def initialize(strategy, strategy_reason, mixed_strategy, mixed_reason)

  # example: parent is only available in xpath strategy and cannot be used with from_element which is only available in uiautomator strategy
  msg = "strategy mix exception: '#{strategy_reason}' is only available in #{strategy} strategy and cannot be used with '#{mixed_reason}' which is only available in #{mixed_strategy} strategy"
  super(msg)
end