Skip to content

Commit 1e047b0

Browse files
committedJul 31, 2013
Minitest 5 only
Add device
1 parent 7ef93e9 commit 1e047b0

File tree

1 file changed

+6
-4
lines changed

1 file changed

+6
-4
lines changed
 

‎lib/appium_lib/driver.rb

+6-4
Original file line numberDiff line numberDiff line change
@@ -79,7 +79,8 @@ def update data, *args
7979
end
8080
end
8181

82-
module MiniTest
82+
# Fix uninitialized constant Minitest (NameError)
83+
module Minitest
8384
class Spec; end
8485
end
8586

@@ -114,9 +115,9 @@ module Appium
114115
class Driver
115116
@@loaded = false
116117

117-
attr_reader :default_wait, :app_path, :app_name,
118+
attr_reader :default_wait, :app_path, :app_name, :device,
118119
:app_package, :app_activity, :app_wait_activity,
119-
:sauce_username, :sauce_access_key, :port, :os, :debug
120+
:sauce_username, :sauce_access_key, :port, :debug
120121
# Creates a new driver.
121122
# :device is :android, :ios, or :selendroid
122123
#
@@ -218,7 +219,8 @@ def initialize opts={}
218219
@@loaded = true
219220
# Promote Appium driver methods to Object instance methods.
220221
$driver.public_methods(false).each do | m |
221-
::MiniTest::Spec.class_eval do
Has conversations. Original line has conversations.
222+
# not MiniTest::Spec
223+
::Minitest::Spec.class_eval do
222224
define_method m do | *args, &block |
223225
begin
224226
# puts "[Object.class_eval] Calling super for '#{m}'"

0 commit comments

Comments
 (0)
Please sign in to comment.