<% if with_lib == 'true' -%> $LOAD_PATH.unshift(File.join(File.dirname(__FILE__), '../../', 'lib')) <% end -%> require 'rspec-expectations' <% unless pageobject_driver.downcase == 'none' -%> require 'page-object' <% end -%> <% if with_gametel == 'true' -%> require 'gametel' <% end -%> <% if with_mohawk == 'true' -%> require 'childprocess' require 'mohawk' <% end -%> <% if with_lib == 'true' -%> require 'require_all' require_all 'lib' <% end -%> <% if with_gametel == 'true' -%> World(Gametel::Navigation) keystore = { :path => File.expand_path('~/.android/debug.keystore'), :alias => 'androiddebugkey', :password => 'android', :keystore_password => 'android' } Gametel.apk_path = PATH_TO_APK Gametel.keystore = keystore Before do @driver = Gametel.start(ACTIVITY_NAME_GOES_HERE) end After do Gametel.stop end <% end -%> <% unless pageobject_driver.downcase == 'none' -%> World(PageObject::PageFactory) <% end -%> <% if with_mohawk == 'true' -%> World(Mohawk::Navigation) Before do @process = ChildProcess.build(PATH_TO_EXECUTABLE) @process.start RAutomation::WaitHelper.wait_until {RAutomation::Window.new(:pid => @process.pid).present?} end After do @process.stop end <% end -%>