Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
20 changes: 0 additions & 20 deletions lib/appium_lib_core/device.rb
Original file line number Diff line number Diff line change
Expand Up @@ -20,26 +20,6 @@ module Device
class << self
def extended(_mod)
extend_webdriver_with_forwardable

# Compatibility for appium_lib. Below command are extended by `extend Appium::Core::Deivce`in appium_lib.
# TODO: Will remove
[
:take_element_screenshot, :save_viewport_screenshot,
:lock, :device_locked?, :unlock,
:hide_keyboard, :is_keyboard_shown,
:ime_activate, :ime_available_engines, :ime_active_engine, :ime_activated, :ime_deactivate,
:get_settings, :update_settings,
:within_context, :current_context, :available_contexts, :set_context,
:push_file, :pull_file, :pull_folder,
:keyevent, :press_keycode, :long_press_keycode,
:match_images_features, :find_image_occurrence, :get_images_similarity, :compare_images,
:app_strings, :background_app,
:install_app, :remove_app, :app_installed?, :activate_app, :terminate_app,
:app_state,
:stop_recording_screen, :stop_and_save_recording_screen,
:shake, :device_time,
:execute_driver, :execute_cdp
].each(&method(:delegate_from_appium_driver))
end

# def extended
Expand Down
38 changes: 0 additions & 38 deletions test/unit/android/device/w3c/definition_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -42,44 +42,6 @@ def parameterized_method_defined_check(array)
delegate_from_appium_driver(v)
end
end

def test_with_arg_definitions
parameterized_method_defined_check([:shake,
:device_locked?,
:unlock,
:device_time,
:current_context,
:open_notifications,
:current_activity,
:current_package,
:get_system_bars,
:get_display_density,
:is_keyboard_shown,
:available_contexts,
:set_context,
:app_strings,
:lock,
:install_app,
:remove_app,
:app_installed?,
:terminate_app,
:activate_app,
:app_state,
:background_app,
:hide_keyboard,
:keyevent,
:press_keycode,
:long_press_keycode,
:push_file,
:pull_file,
:pull_folder,
:get_settings,
:update_settings,
:get_clipboard,
:set_clipboard,
:execute_driver,
:execute_cdp])
end
end # class DefinitionTest
end # module W3C
Comment on lines 42 to 46
end # module Device
Expand Down
37 changes: 0 additions & 37 deletions test/unit/ios/device/w3c/definition_test.rb
Original file line number Diff line number Diff line change
Expand Up @@ -32,10 +32,6 @@ def test_delegate_driver_method
assert @driver.respond_to? :device_locked?
end

def test_delegate_from_appium_driver
assert @core.send(:delegated_target_for_test).respond_to? :device_locked?
end

def delegate_from_appium_driver(key)
assert @core.send(:delegated_target_for_test).respond_to? key
end
Comment on lines 35 to 37
Expand All @@ -46,39 +42,6 @@ def parameterized_method_defined_check(array)
delegate_from_appium_driver(v)
end
end

def test_with_arg_definitions
parameterized_method_defined_check([:shake,
:device_locked?,
:unlock,
:device_time,
:current_context,
:available_contexts,
:set_context,
:app_strings,
:lock,
:install_app,
:remove_app,
:terminate_app,
:activate_app,
:app_state,
:app_installed?,
:background_app,
:hide_keyboard,
:keyevent,
:press_keycode,
:long_press_keycode,
:push_file,
:pull_file,
:pull_folder,
:get_clipboard,
:set_clipboard,
:get_settings,
:update_settings,
:touch_id,
:toggle_touch_id_enrollment,
:execute_driver])
end
end # class DefinitionTest
end # module W3C
end # module Device
Expand Down
Loading