Skip to content

Commit 2278c8e

Browse files
Add wait param to start_driver
1 parent f5f82c0 commit 2278c8e

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

lib/appium_lib/console.rb

+3-4
Original file line numberDiff line numberDiff line change
@@ -72,9 +72,6 @@
7272
require 'android/generic'
7373
end
7474

75-
# implicit_wait default_wait
76-
$default_wait = 30
77-
7875
# WebDriver capabilities. Must be valid for Sauce to work.
7976
# https://github.com/jlipps/appium/blob/master/app/android.js
8077
def android_capabilities
@@ -140,10 +137,12 @@ def driver_quit
140137

141138
# Creates a new global driver and quits the old one if it exists.
142139
# @return [Selenium::WebDriver] the new global driver
143-
def start_driver
140+
def start_driver wait=30
144141
@client = @client || Selenium::WebDriver::Remote::Http::Default.new
145142
@client.timeout = 999999
146143

144+
$default_wait = wait
145+
147146
# If the driver already exists, quit before creating a new driver.
148147
driver_quit
149148

0 commit comments

Comments
 (0)