Fixed file upload on remote browsers.
This commit is contained in:
parent
5d4876a5e5
commit
b066064ec9
1 changed files with 25 additions and 24 deletions
|
@ -69,6 +69,12 @@ class TestCase < Test::Unit::TestCase
|
||||||
browser_instance_preferences(local_browser)
|
browser_instance_preferences(local_browser)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
# upload files from remote dir
|
||||||
|
local_browser.file_detector = lambda do |args|
|
||||||
|
str = args.first.to_s
|
||||||
|
str if File.file?(str)
|
||||||
|
end
|
||||||
|
|
||||||
local_browser
|
local_browser
|
||||||
end
|
end
|
||||||
|
|
||||||
|
@ -88,11 +94,6 @@ class TestCase < Test::Unit::TestCase
|
||||||
end
|
end
|
||||||
end
|
end
|
||||||
local_browser.manage.timeouts.implicit_wait = 3 # seconds
|
local_browser.manage.timeouts.implicit_wait = 3 # seconds
|
||||||
|
|
||||||
local_browser.file_detector = lambda do |args|
|
|
||||||
str = args.first.to_s
|
|
||||||
str if File.exist?(str)
|
|
||||||
end
|
|
||||||
end
|
end
|
||||||
|
|
||||||
def teardown
|
def teardown
|
||||||
|
|
Loading…
Reference in a new issue