Back button in iOS not working? (Ruby)

I have a problem with ‘go back’ in iOS (in Ruby)
In Android this code works but on iOS - unfortunately not:

@driver =
… some operations, to go to one screen in application

Error is:

Back button is null and can’t be tapped.

My Appium version:
appium_console 1.0.3
appium_lib 6.0.0
Appium GUI 1.3.6

Working on simulator of iPhone5, SDK 8.1

You could try this back helper method for iOS.

How to use this method? When I call it:

def myMethod

then I have “undefinied variable or method”.

When I copy-paste this method, then “wait” method is undefinied.

I have:


gem ‘appium_console’
gem ‘appium_lib’, ‘~> 6.0.0’

I can only use methods from driver, for example:



Sorry for that easy questions, I’m really new into Ruby and Appium.

OK I know solution:

I forgot about:

Appium.promote_appium_methods Object

Now everything is working! Thank you!