From 8f2049ff18e3dc20b7cd7a30cd15b0fcb1676341 Mon Sep 17 00:00:00 2001 From: bootstraponline Date: Thu, 17 Apr 2014 14:27:08 -0400 Subject: [PATCH 1/2] Update capabilities and appium.txt --- appium_lib.gemspec | 4 +- lib/appium_lib.rb | 2 + lib/appium_lib/device/device.rb | 2 - lib/appium_lib/driver.rb | 384 ++++++++---------- lib/appium_lib/rails/duplicable.rb | 116 ++++++ ruby_lib_android/appium.txt | 5 +- .../lib/android/specs/android/helper.rb | 9 +- ruby_lib_android/lib/android/specs/driver.rb | 107 ++--- ruby_lib_android/lib/run.rb | 12 +- ruby_lib_android/readme.md | 4 +- ruby_lib_ios/Gemfile | 3 +- ruby_lib_ios/appium.txt | 5 +- ruby_lib_ios/lib/ios/specs/driver.rb | 103 ++--- ruby_lib_ios/lib/run.rb | 12 +- ruby_lib_ios/readme.md | 4 +- 15 files changed, 388 insertions(+), 384 deletions(-) create mode 100644 lib/appium_lib/rails/duplicable.rb diff --git a/appium_lib.gemspec b/appium_lib.gemspec index 5eb7d636..3bf44907 100644 --- a/appium_lib.gemspec +++ b/appium_lib.gemspec @@ -24,13 +24,13 @@ Gem::Specification.new do |s| s.homepage = 'https://github.com/appium/ruby_lib' # published as appium_lib s.require_paths = [ 'lib' ] - s.add_runtime_dependency 'selenium-webdriver', '~> 2.39', '>= 2.39.0' + s.add_runtime_dependency 'selenium-webdriver', '~> 2.41', '>= 2.41.0' s.add_runtime_dependency 'awesome_print', '~> 1.2', '>= 1.2.0' s.add_runtime_dependency 'json', '~> 1.8', '>= 1.8.1' s.add_runtime_dependency 'toml', '~> 0.0', '>= 0.0.4' s.add_runtime_dependency 'posix-spawn', '~> 0.3', '>= 0.3.8' - s.add_development_dependency 'rake', '~> 10.0', '>= 10.0.4' + s.add_development_dependency 'rake', '~> 10.2', '>= 10.2.2' s.add_development_dependency 'yard', '~> 0.8', '>= 0.8.7.3' s.files = `git ls-files`.split "\n" diff --git a/lib/appium_lib.rb b/lib/appium_lib.rb index eb08a91b..99564f68 100644 --- a/lib/appium_lib.rb +++ b/lib/appium_lib.rb @@ -1,4 +1,6 @@ # encoding: utf-8 +require 'Forwardable' unless defined? Forwardable +require_relative 'appium_lib/rails/duplicable' $driver = nil diff --git a/lib/appium_lib/device/device.rb b/lib/appium_lib/device/device.rb index 4b01fab8..76de1965 100644 --- a/lib/appium_lib/device/device.rb +++ b/lib/appium_lib/device/device.rb @@ -1,5 +1,3 @@ -require 'Forwardable' - module Appium module Device extend Forwardable diff --git a/lib/appium_lib/driver.rb b/lib/appium_lib/driver.rb index e0b895b6..41d2fd57 100644 --- a/lib/appium_lib/driver.rb +++ b/lib/appium_lib/driver.rb @@ -12,110 +12,107 @@ # /awesome_print/lib/awesome_print/formatter.rb # upstream issue: https://github.com/michaeldv/awesome_print/pull/36 class AwesomePrint::Formatter - remove_const :CORE if defined?(CORE) - CORE = [ :array, :hash, :class, :file, :dir, :bigdecimal, :rational, :struct, :openstruct, :method, :unboundmethod ] + remove_const :CORE if defined?(CORE) + CORE = [:array, :hash, :class, :file, :dir, :bigdecimal, :rational, :struct, :openstruct, :method, :unboundmethod] def awesome_openstruct target awesome_hash target.marshal_dump end end -# Load appium.txt (toml format) into system ENV + +# Fix uninitialized constant Minitest (NameError) +module Minitest + # Fix superclass mismatch for class Spec + class Runnable + end + class Test < Runnable + end + class Spec < Test + end +end + +module Appium + add_to_path __FILE__ +# Load appium.txt (toml format) # the basedir of this file + appium.txt is what's used +# +# ``` +# [caps] +# app = "path/to/app" +# +# [appium_lib] +# port = 8080 +# ``` +# +# :app is expanded +# :requires are expanded +# all keys are converted to symbols +# # @param opts [Hash] file: '/path/to/appium.txt', verbose: true -# @return [Array] the require files. nil if require doesn't exist -def load_appium_txt opts - raise 'opts must be a hash' unless opts.kind_of? Hash - opts.each_pair { |k,v| opts[k.to_s.downcase.strip.intern] = v } - opts = {} if opts.nil? - file = opts.fetch :file, nil - raise 'Must pass file' unless file - verbose = opts.fetch :verbose, false - # Check for env vars in .txt - parent_dir = File.dirname file - toml = File.expand_path File.join parent_dir, 'appium.txt' - puts "appium.txt path: #{toml}" if verbose - # @private - def update data, *args - args.each do |name| - var = data[name] - ENV[name] = var if var - end - end +# @return [hash] the symbolized hash with updated :app and :require keys + def self.load_appium_txt opts={} + raise 'opts must be a hash' unless opts.kind_of? Hash + raise 'opts must not be empty' if opts.empty? + + file = opts[:file] + raise 'Must pass file' unless file + verbose = opts.fetch :verbose, false + + parent_dir = File.dirname file + toml = File.expand_path File.join parent_dir, 'appium.txt' + puts "appium.txt path: #{toml}" if verbose - toml_exists = File.exists? toml - puts "Exists? #{toml_exists}" if verbose - data = nil + toml_exists = File.exists? toml + puts "Exists? #{toml_exists}" if verbose - if toml_exists + raise "toml doesn't exist ##{toml}" unless toml_exists require 'toml' puts "Loading #{toml}" if verbose - # bash requires A="OK" - # toml requires A = "OK" - # - # A="OK" => A = "OK" data = File.read toml - - data = data.split("\n").map do |line| - line.sub /([^\s])\=/, "\\1 = " - end.join "\n" - data = TOML::Parser.new(data).parsed ap data unless data.empty? if verbose - update data, 'APP_PATH', 'APP_APK', 'APP_PACKAGE', - 'APP_ACTIVITY', 'APP_WAIT_ACTIVITY', - 'DEVICE' - - # ensure app path is resolved correctly from the context of the .txt file - ENV['APP_PATH'] = Appium::Driver.absolute_app_path ENV['APP_PATH'] - end - - # return list of require files as an array - # nil if require doesn't exist - if data && data['require'] - r = data['require'] - r = r.kind_of?(Array) ? r : [ r ] - # ensure files are absolute - r.map! do |file| - file = file.include?(File::Separator) ? file : - File.join(parent_dir, file) - file = File.expand_path file - - File.exists?(file) ? file : nil + if data && data[:caps] && data[:caps][:app] + data[:caps][:app] = Appium::Driver.absolute_app_path data[:caps][:app] end - r.compact! # remove nils - - files = [] - # now expand dirs - r.each do |item| - unless File.directory? item - # save file - files << item - next # only look inside folders + # return list of require files as an array + # nil if require doesn't exist + if data && data[:appium_lib] && data[:appium_lib][:require] + r = data[:appium_lib][:require] + r = r.kind_of?(Array) ? r : [r] + # ensure files are absolute + r.map! do |file| + file = file.include?(File::Separator) ? file : + File.join(parent_dir, file) + file = File.expand_path file + + File.exists?(file) ? file : nil end - Dir.glob(File.join(item, '**/*.rb')) do |file| - # do not add folders to the file list - files << File.expand_path(file) unless File.directory? file + r.compact! # remove nils + + files = [] + + # now expand dirs + r.each do |item| + unless File.directory? item + # save file + files << item + next # only look inside folders + end + Dir.glob(File.join(item, '**/*.rb')) do |file| + # do not add folders to the file list + files << File.expand_path(file) unless File.directory? file + end end + + data[:appium_lib][:require] = files end - files + Appium::symbolize_keys data end -end - -# Fix uninitialized constant Minitest (NameError) -module Minitest - # Fix superclass mismatch for class Spec - class Runnable; end - class Test < Runnable; end - class Spec < Test; end -end - -module Appium - add_to_path __FILE__ require 'selenium-webdriver' @@ -147,6 +144,20 @@ module Appium # device methods require_relative 'device/device' + # convert all keys (including nested) to symbols + # + # based on deep_symbolize_keys & deep_transform_keys from rails + # https://github.com/rails/docrails/blob/a3b1105ada3da64acfa3843b164b14b734456a50/activesupport/lib/active_support/core_ext/hash/keys.rb#L84 + def self.symbolize_keys hash + raise 'symbolize_keys requires a hash' unless hash.is_a? Hash + result = {} + hash.each do |key, value| + key = key.to_sym rescue key + result[key] = value.is_a?(Hash) ? symbolize_keys(value) : value + end + result + end + def self.promote_singleton_appium_methods main_module raise 'Driver is nil' if $driver.nil? main_module.constants.each do |sub_module| @@ -190,9 +201,9 @@ def self.promote_appium_methods class_array # Prefer existing method. # super will invoke method missing on driver super(*args, &block) - # minitest also defines a name method, - # so rescue argument error - # and call the name method on $driver + # minitest also defines a name method, + # so rescue argument error + # and call the name method on $driver rescue NoMethodError, ArgumentError $driver.send m, *args, &block if $driver.respond_to?(m) end @@ -206,10 +217,8 @@ def self.promote_appium_methods class_array class Driver @@loaded = false - attr_reader :default_wait, :app_path, :app_name, :device, - :app_package, :app_activity, :app_wait_activity, - :sauce_username, :sauce_access_key, :port, :debug, - :export_session, :device_cap, :compress_xml, :custom_url + # attr readers are promoted to global scope. To avoid clobbering, they're + # made available via the driver_attributes method # The amount to sleep in seconds before every webdriver http call. attr_accessor :global_webdriver_http_sleep @@ -245,75 +254,36 @@ class Driver def initialize opts={} # quit last driver $driver.driver_quit if $driver - opts = {} if opts.nil? - tmp_opts = {} - - # convert to downcased symbols - opts.each_pair { |k,v| tmp_opts[k.to_s.downcase.strip.intern] = v } - opts = tmp_opts - - @raw_capabilities = opts.fetch(:raw, {}) + raise 'opts must be a hash' unless opts.kind_of? Hash - @custom_url = opts.fetch :server_url, false + opts = Appium::symbolize_keys opts - @compress_xml = opts[:compress_xml] ? true : false + # default to {} to prevent nil.fetch and other nil errors + @caps = opts[:caps] || {} + appium_lib_opts = opts[:appium_lib] || {} - @export_session = opts.fetch :export_session, false - - @default_wait = opts.fetch :wait, 30 - @last_waits = [@default_wait] + # appium_lib specific values + @custom_url = appium_lib_opts.fetch :server_url, false + @export_session = appium_lib_opts.fetch :export_session, false + @default_wait = appium_lib_opts.fetch :wait, 30 + @last_waits = [@default_wait] + @sauce_username = appium_lib_opts.fetch :sauce_username, ENV['SAUCE_USERNAME'] + @sauce_access_key = appium_lib_opts.fetch :sauce_access_key, ENV['SAUCE_ACCESS_KEY'] + @port = appium_lib_opts.fetch :port, 4723 # Path to the .apk, .app or .app.zip. # The path can be local or remote for Sauce. - @app_path = opts.fetch :app_path, ENV['APP_PATH'] - raise 'APP_PATH must be set.' if @app_path.nil? - - # The name to use for the test run on Sauce. - @app_name = opts.fetch :app_name, ENV['APP_NAME'] - - # Android app package - @app_package = opts.fetch :app_package, ENV['APP_PACKAGE'] - - # Android app starting activity. - @app_activity = opts.fetch :app_activity, ENV['APP_ACTIVITY'] - - # Android app waiting activity - @app_wait_activity = opts.fetch :app_wait_activity, ENV['APP_WAIT_ACTIVITY'] - - @android_coverage = opts.fetch :android_coverage, ENV['ANDROID_COVERAGE'] - # init to empty hash because it's merged later as an optional desired cap. - @android_coverage = @android_coverage ? { androidCoverage: @android_coverage} : {} - - # Sauce Username - @sauce_username = opts.fetch :sauce_username, ENV['SAUCE_USERNAME'] - - # Sauce Key - @sauce_access_key = opts.fetch :sauce_access_key, ENV['SAUCE_ACCESS_KEY'] - - @port = opts.fetch :port, ENV['PORT'] || 4723 - - # 'iPhone Simulator' - # 'iPad Simulator' - # 'Android' - # 'Selendroid' - # - # :ios, :android, :selendroid - @device = opts.fetch :device, ENV['DEVICE'] - raise 'Device must be set' unless @device - - @device_type = opts.fetch :device_type, 'tablet' - @device_orientation = opts.fetch :device_orientation, 'portrait' - - @full_reset = opts.fetch :full_reset, true - @no_reset = opts.fetch :no_reset, false + unless !@caps || @caps[:app].nil? || @caps[:app].empty? + @caps[:app] = self.class.absolute_app_path @caps[:app] + end - # no_reset/full_reset are mutually exclusive - @no_reset = false if @full_reset - @full_reset = false if @no_reset + # https://code.google.com/p/selenium/source/browse/spec-draft.md?repo=mobile + @device = @caps[:platformName] + raise "Device must be set. Not found in options: #{opts}" unless @device # load common methods extend Appium::Common - if @device.downcase == 'android' + if @device.downcase.strip == 'android' # load Android specific methods extend Appium::Android else @@ -326,7 +296,7 @@ def initialize opts={} # enable debug patch # !!'constant' == true - @debug = opts.fetch :debug, !!defined?(Pry) + @debug = appium_lib_opts.fetch :debug, !!defined?(Pry) puts "Debug is: #{@debug}" if @debug ap opts unless opts.empty? @@ -349,73 +319,46 @@ def initialize opts={} end self # return newly created driver - end # def initialize + end - # Returns the status payload + # Returns a hash of the driver attributes + def driver_attributes + attributes = { caps: @caps, + custom_url: @custom_url, + export_session: @export_session, + default_wait: @default_wait, + last_waits: @last_waits, + sauce_username: @sauce_username, + sauce_access_key: @sauce_access_key, + port: @port, + device: @device, + debug: @debug, + } + + # Return duplicates so attributes are immutable + attributes.each do |key, value| + attributes[key] = value.duplicable? ? value.dup : value + end + attributes + end + + # Returns the server's version info # # ```ruby - # {"status"=>0, - # "value"=> - # {"build"=> - # {"version"=>"0.8.2", - # "revision"=>"f2a2bc3782e4b0370d97a097d7e04913cf008995"}}, - # "sessionId"=>"8f4b34a7-a9a9-4ac5-b125-36258143446a"} + # { + # "build" => { + # "version" => "0.18.1", + # "revision" => "d242ebcfd92046a974347ccc3a28f0e898595198" + # } + # } # ``` # - # Discover the Appium rev running on the server. - # - # `status["value"]["build"]["revision"]` - # `f2a2bc3782e4b0370d97a097d7e04913cf008995` - # - # @return [JSON] - def status - driver.status.payload - end - - # Returns the server's version string - # @return [String] - def server_version - status['value']['build']['version'] + # @return [Hash] + def appium_server_version + driver.remote_status end - # @private - # WebDriver capabilities. Must be valid for Sauce to work. - # https://github.com/jlipps/appium/blob/master/app/android.js - def android_capabilities - { - compressXml: @compress_xml, - platform: 'Linux', - platformName: @device, - fullReset: @full_reset, - noReset: @no_reset, - :'device-type' => @device_type, - :'device-orientation' => @device_orientation, - name: @app_name || 'Ruby Console Android Appium', - :'app-package' => @app_package, - :'app-activity' => @app_activity, - :'app-wait-activity' => @app_wait_activity || @app_activity, - }.merge(@android_coverage).merge(@raw_capabilities) - end - - # @private - # WebDriver capabilities. Must be valid for Sauce to work. - def ios_capabilities - { - platform: 'OS X 10.9', - platformName: @device, - name: @app_name || 'Ruby Console iOS Appium', - :'device-orientation' => @device_orientation - }.merge(@raw_capabilities) - end - - # @private - def capabilities - caps = @device.downcase === 'android' ? android_capabilities : ios_capabilities - caps[:app] = self.class.absolute_app_path(@app_path) unless @app_path.nil? || @app_path.empty? - caps - end - - # Converts environment variable APP_PATH to an absolute path. + # Converts app_path to an absolute path. # @return [String] APP_PATH as an absolute path def self.absolute_app_path app_path raise 'APP_PATH not set!' if app_path.nil? || app_path.empty? @@ -439,7 +382,7 @@ def self.absolute_app_path app_path app_path end - # Get the server url for sauce or local based on env vars. + # Get the server url # @return [String] the server url def server_url return @custom_url if @custom_url @@ -477,30 +420,27 @@ def screenshot png_save_path # Quits the driver # @return [void] def driver_quit - # rescue NoSuchDriverError - begin; @driver.quit unless @driver.nil?; rescue; end + # rescue NoSuchDriverError or nil driver + @driver.quit rescue nil end # Creates a new global driver and quits the old one if it exists. # # @return [Selenium::WebDriver] the new global driver def start_driver - @client = @client || Selenium::WebDriver::Remote::Http::Default.new + @client = @client || Selenium::WebDriver::Remote::Http::Default.new @client.timeout = 999999 begin - @driver = Selenium::WebDriver.for :remote, http_client: @client, desired_capabilities: capabilities, url: server_url + @driver = Selenium::WebDriver.for :remote, http_client: @client, desired_capabilities: @caps, url: server_url # Load touch methods. Required for Selendroid. @driver.extend Selenium::WebDriver::DriverExtensions::HasTouchScreen # export session if @export_session - begin - File.open('/tmp/appium_lib_session', 'w') do |f| - f.puts @driver.session_id - end - rescue - end + File.open('/tmp/appium_lib_session', 'w') do |f| + f.puts @driver.session_id + end rescue nil end rescue Errno::ECONNREFUSED raise 'ERROR: Unable to connect to Appium. Is the server running?' @@ -519,8 +459,8 @@ def start_driver # Set implicit wait and default_wait to zero. def no_wait - @last_waits = [@default_wait, 0] - @default_wait = 0 + @last_waits = [@default_wait, 0] + @default_wait = 0 @driver.manage.timeouts.implicit_wait = 0 end @@ -545,7 +485,7 @@ def set_wait timeout=nil else @default_wait = timeout # puts "last waits before: #{@last_waits}" - @last_waits = [@last_waits.last, @default_wait] + @last_waits = [@last_waits.last, @default_wait] # puts "last waits after: #{@last_waits}" end @@ -577,7 +517,7 @@ def exists pre_check=0, post_check=@default_wait, &search_block # which then gets converted to a 1 second wait. @driver.manage.timeouts.implicit_wait = pre_check # the element exists unless an error is raised. - exists = true + exists = true begin search_block.call # search for element diff --git a/lib/appium_lib/rails/duplicable.rb b/lib/appium_lib/rails/duplicable.rb new file mode 100644 index 00000000..7c8d59a6 --- /dev/null +++ b/lib/appium_lib/rails/duplicable.rb @@ -0,0 +1,116 @@ +# https://github.com/rails/rails/blob/e120d21211f9644e9b832e51ba7aa6c45448b782/activesupport/lib/active_support/core_ext/object/duplicable.rb +=begin +Copyright (c) 2005-2011 David Heinemeier Hansson + +Permission is hereby granted, free of charge, to any person obtaining +a copy of this software and associated documentation files (the +"Software"), to deal in the Software without restriction, including +without limitation the rights to use, copy, modify, merge, publish, +distribute, sublicense, and/or sell copies of the Software, and to +permit persons to whom the Software is furnished to do so, subject to +the following conditions: + +The above copyright notice and this permission notice shall be +included in all copies or substantial portions of the Software. + +THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, +EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF +MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND +NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE +LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION +OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION +WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. +=end +#-- +# Most objects are cloneable, but not all. For example you can't dup +nil+: +# +# nil.dup # => TypeError: can't dup NilClass +# +# Classes may signal their instances are not duplicable removing +dup+/+clone+ +# or raising exceptions from them. So, to dup an arbitrary object you normally +# use an optimistic approach and are ready to catch an exception, say: +# +# arbitrary_object.dup rescue object +# +# Rails dups objects in a few critical spots where they are not that arbitrary. +# That rescue is very expensive (like 40 times slower than a predicate), and it +# is often triggered. +# +# That's why we hardcode the following cases and check duplicable? instead of +# using that rescue idiom. +#++ +class Object + # Can you safely dup this object? + # + # False for +nil+, +false+, +true+, symbol, and number objects; + # true otherwise. + def duplicable? + true + end +end + +class NilClass + # +nil+ is not duplicable: + # + # nil.duplicable? # => false + # nil.dup # => TypeError: can't dup NilClass + def duplicable? + false + end +end + +class FalseClass + # +false+ is not duplicable: + # + # false.duplicable? # => false + # false.dup # => TypeError: can't dup FalseClass + def duplicable? + false + end +end + +class TrueClass + # +true+ is not duplicable: + # + # true.duplicable? # => false + # true.dup # => TypeError: can't dup TrueClass + def duplicable? + false + end +end + +class Symbol + # Symbols are not duplicable: + # + # :my_symbol.duplicable? # => false + # :my_symbol.dup # => TypeError: can't dup Symbol + def duplicable? + false + end +end + +class Numeric + # Numbers are not duplicable: + # + # 3.duplicable? # => false + # 3.dup # => TypeError: can't dup Fixnum + def duplicable? + false + end +end + +require 'bigdecimal' +class BigDecimal + # Needed to support Ruby 1.9.x, as it doesn't allow dup on BigDecimal, instead + # raises TypeError exception. Checking here on the runtime whether BigDecimal + # will allow dup or not. + begin + BigDecimal.new('4.56').dup + + def duplicable? + true + end + rescue TypeError + # can't dup, so use superclass implementation + end +end \ No newline at end of file diff --git a/ruby_lib_android/appium.txt b/ruby_lib_android/appium.txt index 82ce97ef..f3a5495c 100644 --- a/ruby_lib_android/appium.txt +++ b/ruby_lib_android/appium.txt @@ -1,2 +1,3 @@ -APP_PATH="./api.apk" -DEVICE="android" \ No newline at end of file +[caps] +platformName = "android" +app = "./api.apk" \ No newline at end of file diff --git a/ruby_lib_android/lib/android/specs/android/helper.rb b/ruby_lib_android/lib/android/specs/android/helper.rb index 4647d809..7c39cc55 100644 --- a/ruby_lib_android/lib/android/specs/android/helper.rb +++ b/ruby_lib_android/lib/android/specs/android/helper.rb @@ -1,5 +1,5 @@ # encoding: utf-8 - +# rake android[android/helper] describe 'android/helper' do t 'tag_name_to_android' do act = tag_name_to_android 'abslist' @@ -16,8 +16,12 @@ end t 'find_eles_attr' do + exp = ["API Demos", "Accessibility", "Animation", "App", "Content", "Graphics", "Media", "NFC", "OS", "Preference", "Text", "Views"] + + # must wait for page to load + ignore { wait_true(10) { find_eles_attr(:text) == exp } } act = find_eles_attr :text - exp = ['API Demos', 'Accessibility', 'Animation', 'App', 'Content', 'Graphics', 'Media', 'NFC', 'OS', 'Preference', 'Text', 'Views'] + act.must_equal exp end @@ -54,7 +58,6 @@ def page_class_data fast_duration.must_equal 0.0357 end - def id_key 'animation_2_instructions' end diff --git a/ruby_lib_android/lib/android/specs/driver.rb b/ruby_lib_android/lib/android/specs/driver.rb index 8bdba82c..fac50df9 100644 --- a/ruby_lib_android/lib/android/specs/driver.rb +++ b/ruby_lib_android/lib/android/specs/driver.rb @@ -1,12 +1,14 @@ # encoding: utf-8 # rake android[driver] describe 'driver' do + def is_sauce + ENV['UPLOAD_FILE'] && ENV['SAUCE_USERNAME'] + end + t 'load_appium_txt' do # __FILE__ is '(eval)' so use env var set by the Rakefile - path = ENV['APPIUM_TXT'] - puts "appium.txt path in test is: #{path}" - load_appium_txt file: path, verbose: true - apk_name = File.basename(ENV['APP_PATH']) + parsed = Appium.load_appium_txt file: ENV['APPIUM_TXT'], verbose: true + apk_name = File.basename parsed[:caps][:app] assert_equal apk_name, 'api.apk' end @@ -21,45 +23,28 @@ end t 'app_path attr' do - apk_name = File.basename app_path + apk_name = File.basename driver_attributes[:caps][:app] apk_name.must_equal 'api.apk' end # Only used for Sauce Labs - t 'app_name attr' do - app_name.must_be_nil - end - - t 'device attr' do - device.must_equal 'android' - end - - t 'app_package attr' do - app_package.must_be_nil - end - - t 'app_activity attr' do - app_activity.must_be_nil - end - - t 'app_wait_activity attr' do - app_wait_activity.must_be_nil - end - - t 'sauce_username attr' do - sauce_username.must_be_nil - end - - t 'sauce_access_key attr' do - sauce_access_key.must_be_nil - end - - t 'port attr' do - port.must_equal 4723 - end - - t 'debug attr' do - debug.must_equal true + t 'verify all attributes' do + 2.times { set_wait 1 } # must set twice to validate last_waits + actual = driver_attributes + actual[:caps][:app] = File.basename actual[:caps][:app] + expected = { caps: { platformName: 'android', + app: 'api.apk' }, + custom_url: false, + export_session: false, + default_wait: 1, + last_waits: [1, 1], + sauce_username: nil, + sauce_access_key: nil, + port: 4723, + device: 'android', + debug: true } + + actual.must_equal expected end end @@ -74,8 +59,13 @@ end t 'absolute_app_path' do - def absolute_app_path path; $driver.class.absolute_app_path path; end - def validate_path path; absolute_app_path(path).must_equal path; end + def absolute_app_path path; + $driver.class.absolute_app_path path; + end + + def validate_path path; + absolute_app_path(path).must_equal path; + end validate_path 'sauce-storage:some_storage_suffix' validate_path 'http://www.saucelabs.com' @@ -107,7 +97,7 @@ def validate_path path; absolute_app_path(path).must_equal path; end # invalid path test invalid_path_errors = false begin - absolute_app_path('../../does_not_exist.apk') + absolute_app_path('../../does_not_exist.apk') rescue Exception invalid_path_errors = true ensure @@ -118,34 +108,16 @@ def validate_path path; absolute_app_path(path).must_equal path; end describe 'methods' do t 'status' do - status.keys.sort.must_equal %w(sessionId status value) + appium_server_version['build'].keys.sort.must_equal %w(revision version) end t 'server_version' do - server_version.must_match /(\d+)\.(\d+).(\d+)/ - end - - def expected_android_capabilities - { :compressXml => false, - :platform => 'Linux', - :platformName => 'android', - :fullReset => true, - :noReset => false, - :'device-type' => 'tablet', - :'device-orientation' => 'portrait', - :name => 'Ruby Console Android Appium', - :'app-package' => nil, - :'app-activity' => nil, - :'app-wait-activity' => nil, - app: 'api.apk' } - end - - t 'capabilities' do - exp = expected_android_capabilities - - act = capabilities - act[:app] = File.basename act[:app] - act.must_equal exp + server_version = appium_server_version['build']['version'] + if is_sauce + server_version.must_match 'Sauce OnDemand' + else + server_version.must_match /(\d+)\.(\d+).(\d+)/ + end end =begin @@ -173,6 +145,7 @@ def expected_android_capabilities set_wait # posts value to server, it's not stored locally =end t 'default_wait' do + set_wait 1 default_wait.must_equal 1 end diff --git a/ruby_lib_android/lib/run.rb b/ruby_lib_android/lib/run.rb index d8798ba8..65daaf74 100644 --- a/ruby_lib_android/lib/run.rb +++ b/ruby_lib_android/lib/run.rb @@ -17,8 +17,6 @@ a = OpenStruct.new x: 'ok' raise 'x issue' unless a.x == 'ok' -load_appium_txt file: ENV['APPIUM_TXT'], verbose: true - dir = File.expand_path '..', __FILE__ device = ARGV[0].downcase.strip devices = %w[ android selendroid ios ] @@ -27,13 +25,11 @@ one_test = ARGV[1] test_dir = "/#{device}/" -puts 'Start driver' -use_selendroid = device == 'selendroid' -puts "Use selendroid? #{use_selendroid}" - -ENV['APP_PATH'] = ENV['SAUCE_PATH'] if ENV['SAUCE_USERNAME'] && ENV['SAUCE_ACCESS_KEY'] +caps = Appium.load_appium_txt file: ENV['APPIUM_TXT'], verbose: true +caps = caps.merge({ appium_lib: { debug: true, wait: 1 } }) +caps[:app] = ENV['SAUCE_PATH'] if ENV['SAUCE_USERNAME'] && ENV['SAUCE_ACCESS_KEY'] -Appium::Driver.new(fast_clear: true, debug: true, wait: 1).start_driver +Appium::Driver.new(caps).start_driver =begin # Android doesn't like to be reset before booting up diff --git a/ruby_lib_android/readme.md b/ruby_lib_android/readme.md index 8a0caee6..70e5fa39 100644 --- a/ruby_lib_android/readme.md +++ b/ruby_lib_android/readme.md @@ -21,7 +21,7 @@ api.apk is from [appium/android-apidemos](https://github.com/appium/android-apid -- ```java -Finished in 2 mins 12 secs +Finished in 2 mins 8 secs -103 runs, 129 assertions, 0 failures, 0 errors, 0 skips +94 runs, 120 assertions, 0 failures, 0 errors, 0 skips ``` diff --git a/ruby_lib_ios/Gemfile b/ruby_lib_ios/Gemfile index b8f90810..fcce1af9 100644 --- a/ruby_lib_ios/Gemfile +++ b/ruby_lib_ios/Gemfile @@ -1,3 +1,4 @@ source 'https://rubygems.org' gem 'test_runner', '>= 0.9.37' -gem 'rake', '~> 10.2.2' \ No newline at end of file +gem 'rake', '~> 10.2.2' +gem 'selenium-webdriver', '>= 2.41.0' \ No newline at end of file diff --git a/ruby_lib_ios/appium.txt b/ruby_lib_ios/appium.txt index 99efc45e..3d19a0cd 100644 --- a/ruby_lib_ios/appium.txt +++ b/ruby_lib_ios/appium.txt @@ -1,2 +1,3 @@ -DEVICE="ios" -APP_PATH="./UICatalog.app" +[caps] +platformName = "ios" +app = "./UICatalog.app" \ No newline at end of file diff --git a/ruby_lib_ios/lib/ios/specs/driver.rb b/ruby_lib_ios/lib/ios/specs/driver.rb index 8898daac..8cf5aeff 100644 --- a/ruby_lib_ios/lib/ios/specs/driver.rb +++ b/ruby_lib_ios/lib/ios/specs/driver.rb @@ -13,16 +13,41 @@ def is_sauce skip if is_sauce # __FILE__ is '(eval)' so use env var set by the Rakefile path = ENV['APPIUM_TXT'] - puts "appium.txt path in test is: #{path}" - load_appium_txt file: path, verbose: true - apk_name = File.basename(ENV['APP_PATH']) - assert_equal apk_name, 'UICatalog.app' + opts = Appium.load_appium_txt file: path, verbose: true + + actual = '' + actual = File.basename opts[:caps][:app] if opts && opts[:caps] + expected = 'UICatalog.app' + assert_equal expected, actual end describe 'Appium::Driver attributes' do - # attr_reader :default_wait, :app_path, :app_name, :selendroid, - # :app_package, :app_activity, :app_wait_activity, - # :sauce_username, :sauce_access_key, :port, :os, :debug + t 'verify all attributes' do + 2.times { set_wait 30 } # must set twice to validate last_waits + actual = driver_attributes + actual[:caps][:app] = File.basename actual[:caps][:app] + expected = { caps: { platformName: 'ios', + app: 'UICatalog.app' }, + custom_url: false, + export_session: false, + default_wait: 30, + last_waits: [30, 30], + sauce_username: nil, + sauce_access_key: nil, + port: 4723, + device: 'ios', + debug: true } + + actual.must_equal expected + end + + t 'verify attributes are immutable' do + driver_attributes[:caps][:app] = 'fake' + actual = File.basename driver_attributes[:caps][:app] + expected = 'UICatalog.app' + actual.must_equal expected + end + t 'no_wait' do no_wait default_wait.must_equal 0 @@ -36,7 +61,7 @@ def is_sauce end t 'app_path attr' do - apk_name = File.basename app_path + apk_name = File.basename driver_attributes[:caps][:app] if is_sauce apk_name.must_equal 'sauce-storage:UICatalog6.1.app.zip' @@ -47,22 +72,16 @@ def is_sauce # Only used for Sauce Labs t 'app_name attr' do + name_attr = driver_attributes[:caps][:name] if is_sauce - app_name.must_equal 'appium_lib_ios' + name_attr.must_equal 'appium_lib_ios' else - app_name.must_be_nil + name_attr.must_be_nil end end - t 'device attr' do - device.must_equal 'ios' - end - - # t 'app_package attr' do # iOS does not have this attr - # t 'app_activity attr' do # iOS does not have this attr - # t 'app_wait_activity attr' do # iOS does not have this attr - t 'sauce_username attr' do + sauce_username = driver_attributes[:sauce_username] if is_sauce sauce_username.must_equal 'appiumci' else @@ -71,20 +90,13 @@ def is_sauce end t 'sauce_access_key attr' do + sauce_access_key = driver_attributes[:sauce_access_key] if is_sauce sauce_access_key.must_match /\h{8}-\h{4}-\h{4}-\h{4}-\h{12}/ else sauce_access_key.must_be_nil end end - - t 'port attr' do - port.must_equal 4723 - end - - t 'debug attr' do - debug.must_equal true - end end describe 'Appium::Driver' do @@ -100,10 +112,11 @@ def is_sauce describe 'methods' do t 'status' do - status.keys.sort.must_equal %w(sessionId status value) + appium_server_version['build'].keys.sort.must_equal %w(revision version) end t 'server_version' do + server_version = appium_server_version['build']['version'] if is_sauce server_version.must_match 'Sauce OnDemand' else @@ -111,42 +124,6 @@ def is_sauce end end - def expected_ios_capabilities - { - :platform => 'OS X 10.9', - :platformName => 'ios', - :name => 'Ruby Console iOS Appium', - :'device-orientation' => 'portrait', - :app => 'UICatalog.app' - } - end - - def expected_ios_capabilities_sauce - { - platform: 'Mac 10.8', - version: '6.1', - device: 'iPhone Simulator', - name: 'appium_lib_ios', - app: 'sauce-storage:UICatalog6.1.app.zip' - } - end - - # capabilities calls ios_capabilities when device is :ios - t 'capabilities' do - exp = is_sauce ? expected_ios_capabilities_sauce : - expected_ios_capabilities - - act = capabilities - act[:app] = File.basename act[:app] - act.must_equal exp - end - -=begin - Skip: - ios_capabilities # save for iOS tests - absolute_app_path # tested already by starting the driver for this test - server_url # sauce labs only -=end t 'restart' do restart s_text 'buttons' diff --git a/ruby_lib_ios/lib/run.rb b/ruby_lib_ios/lib/run.rb index 397ff1ea..63ea4bca 100644 --- a/ruby_lib_ios/lib/run.rb +++ b/ruby_lib_ios/lib/run.rb @@ -65,7 +65,8 @@ def catalog end ## -load_appium_txt file: File.expand_path('..',__FILE__), verbose: true +caps = Appium.load_appium_txt file: File.expand_path('..',__FILE__), verbose: true +caps = caps.merge({ appium_lib: { debug: true, wait: 30 } }) dir = File.expand_path '..', __FILE__ device = ARGV[0].downcase.strip @@ -75,14 +76,9 @@ def catalog one_test = ARGV[1] test_dir = "/#{device}/" -puts 'Start driver' -use_selendroid = device == 'selendroid' -puts "Use selendroid? #{use_selendroid}" +caps[:app] = ENV['SAUCE_PATH'] if ENV['SAUCE_USERNAME'] && ENV['SAUCE_ACCESS_KEY'] - -ENV['APP_PATH'] = ENV['SAUCE_PATH'] if ENV['SAUCE_USERNAME'] && ENV['SAUCE_ACCESS_KEY'] - -Appium::Driver.new(debug: true, wait: 30).start_driver +Appium::Driver.new(caps).start_driver =begin # Android doesn't like to be reset before booting up diff --git a/ruby_lib_ios/readme.md b/ruby_lib_ios/readme.md index 4f84669f..4a2dd5a7 100644 --- a/ruby_lib_ios/readme.md +++ b/ruby_lib_ios/readme.md @@ -24,7 +24,7 @@ The tests are now run against `iPhone Simulator 7.0.3 (11B508)` -- ```java -Finished in 2 mins 3 secs +Finished in 1 min 49 secs -103 runs, 132 assertions, 0 failures, 0 errors, 0 skips +101 runs, 130 assertions, 0 failures, 0 errors, 0 skips ``` From fb615225eae819eef70153a76e954ffa2991845e Mon Sep 17 00:00:00 2001 From: bootstraponline Date: Thu, 17 Apr 2014 14:31:36 -0400 Subject: [PATCH 2/2] Rename test folders --- {ruby_lib_android => android_tests}/Gemfile | 0 {ruby_lib_android => android_tests}/LICENSE-2.0.txt | 0 {ruby_lib_android => android_tests}/Rakefile | 0 {ruby_lib_android => android_tests}/api.apk | Bin {ruby_lib_android => android_tests}/appium.txt | 0 .../lib/android/specs/android/dynamic.rb | 0 .../lib/android/specs/android/element/alert.rb | 0 .../lib/android/specs/android/element/generic.rb | 0 .../lib/android/specs/android/element/textfield.rb | 0 .../lib/android/specs/android/helper.rb | 0 .../lib/android/specs/android/patch.rb | 0 .../lib/android/specs/common/element/button.rb | 0 .../lib/android/specs/common/element/text.rb | 0 .../lib/android/specs/common/element/window.rb | 0 .../lib/android/specs/common/helper.rb | 0 .../lib/android/specs/common/patch.rb | 0 .../lib/android/specs/common/version.rb | 0 .../lib/android/specs/driver.rb | 0 {ruby_lib_android => android_tests}/lib/format.rb | 0 {ruby_lib_android => android_tests}/lib/run.rb | 0 {ruby_lib_android => android_tests}/readme.md | 0 .../selendroid/appium.txt | 0 {ruby_lib_ios => ios_tests}/Gemfile | 0 {ruby_lib_ios => ios_tests}/LICENSE-2.0.txt | 0 {ruby_lib_ios => ios_tests}/Rakefile | 0 {ruby_lib_ios => ios_tests}/UICatalog.app.zip | Bin .../UICatalog.app/12-6AM.png | Bin .../UICatalog.app/12-6PM.png | Bin .../UICatalog.app/6-12AM.png | Bin .../UICatalog.app/6-12PM.png | Bin .../UICatalog.app/Default-568h@2x.png | Bin .../UICatalog.app/Default@2x.png | Bin .../UICatalog.app/Info.plist | Bin {ruby_lib_ios => ios_tests}/UICatalog.app/PkgInfo | 0 .../UICatalog.app/UIButton_custom.png | Bin {ruby_lib_ios => ios_tests}/UICatalog.app/UICatalog | Bin .../UICatalog.app/blueButton.png | Bin .../UICatalog.app/bookmarkImage.png | Bin .../UICatalog.app/bookmarkImageHighlighted.png | Bin .../UICatalog.app/divider.png | Bin .../UICatalog.app/en.lproj/AlertsViewController.nib | Bin .../en.lproj/ButtonsViewController.nib | Bin .../en.lproj/ControlsViewController.nib | Bin .../UICatalog.app/en.lproj/ImagesViewController.nib | Bin .../UICatalog.app/en.lproj/Localizable.strings | Bin .../UICatalog.app/en.lproj/MainWindow.nib | Bin .../UICatalog.app/en.lproj/PickerViewController.nib | Bin .../UICatalog.app/en.lproj/SearchBarController.nib | Bin .../en.lproj/SegmentViewController.nib | Bin .../UICatalog.app/en.lproj/TextFieldController.nib | Bin .../UICatalog.app/en.lproj/TextViewController.nib | Bin .../en.lproj/ToolbarViewController.nib | Bin .../en.lproj/TransitionViewController.nib | Bin .../UICatalog.app/en.lproj/WebViewController.nib | Bin .../UICatalog.app/orangeslide.png | Bin .../UICatalog.app/scene1.jpg | Bin .../UICatalog.app/scene2.jpg | Bin .../UICatalog.app/scene3.jpg | Bin .../UICatalog.app/scene4.jpg | Bin .../UICatalog.app/scene5.jpg | Bin .../UICatalog.app/searchBarBackground.png | Bin .../UICatalog.app/segment_check.png | Bin .../UICatalog.app/segment_search.png | Bin .../UICatalog.app/segment_tools.png | Bin .../UICatalog.app/segmentedBackground.png | Bin .../UICatalog.app/slider_ball.png | Bin .../UICatalog.app/toolbarBackground.png | Bin .../UICatalog.app/whiteButton.png | Bin .../UICatalog.app/yellowslide.png | Bin {ruby_lib_ios => ios_tests}/appium.txt | 0 {ruby_lib_ios => ios_tests}/lib/format.rb | 0 .../lib/ios/specs/common/element/button.rb | 0 .../lib/ios/specs/common/element/text.rb | 0 .../lib/ios/specs/common/element/window.rb | 0 .../lib/ios/specs/common/helper.rb | 0 .../lib/ios/specs/common/patch.rb | 0 .../lib/ios/specs/common/version.rb | 0 {ruby_lib_ios => ios_tests}/lib/ios/specs/driver.rb | 0 .../lib/ios/specs/ios/element/alert.rb | 0 .../lib/ios/specs/ios/element/generic.rb | 0 .../lib/ios/specs/ios/element/textfield.rb | 0 .../lib/ios/specs/ios/helper.rb | 0 .../lib/ios/specs/ios/patch.rb | 0 {ruby_lib_ios => ios_tests}/lib/run.rb | 0 {ruby_lib_ios => ios_tests}/readme.md | 0 {ruby_lib_ios => ios_tests}/upload/sauce_storage.rb | 0 {ruby_lib_ios => ios_tests}/upload/upload.rb | 0 lib/appium_lib/driver.rb | 2 +- 88 files changed, 1 insertion(+), 1 deletion(-) rename {ruby_lib_android => android_tests}/Gemfile (100%) rename {ruby_lib_android => android_tests}/LICENSE-2.0.txt (100%) rename {ruby_lib_android => android_tests}/Rakefile (100%) rename {ruby_lib_android => android_tests}/api.apk (100%) rename {ruby_lib_android => android_tests}/appium.txt (100%) rename {ruby_lib_android => android_tests}/lib/android/specs/android/dynamic.rb (100%) rename {ruby_lib_android => android_tests}/lib/android/specs/android/element/alert.rb (100%) rename {ruby_lib_android => android_tests}/lib/android/specs/android/element/generic.rb (100%) rename {ruby_lib_android => android_tests}/lib/android/specs/android/element/textfield.rb (100%) rename {ruby_lib_android => android_tests}/lib/android/specs/android/helper.rb (100%) rename {ruby_lib_android => android_tests}/lib/android/specs/android/patch.rb (100%) rename {ruby_lib_android => android_tests}/lib/android/specs/common/element/button.rb (100%) rename {ruby_lib_android => android_tests}/lib/android/specs/common/element/text.rb (100%) rename {ruby_lib_android => android_tests}/lib/android/specs/common/element/window.rb (100%) rename {ruby_lib_android => android_tests}/lib/android/specs/common/helper.rb (100%) rename {ruby_lib_android => android_tests}/lib/android/specs/common/patch.rb (100%) rename {ruby_lib_android => android_tests}/lib/android/specs/common/version.rb (100%) rename {ruby_lib_android => android_tests}/lib/android/specs/driver.rb (100%) rename {ruby_lib_android => android_tests}/lib/format.rb (100%) rename {ruby_lib_android => android_tests}/lib/run.rb (100%) rename {ruby_lib_android => android_tests}/readme.md (100%) rename {ruby_lib_android => android_tests}/selendroid/appium.txt (100%) rename {ruby_lib_ios => ios_tests}/Gemfile (100%) rename {ruby_lib_ios => ios_tests}/LICENSE-2.0.txt (100%) rename {ruby_lib_ios => ios_tests}/Rakefile (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app.zip (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/12-6AM.png (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/12-6PM.png (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/6-12AM.png (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/6-12PM.png (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/Default-568h@2x.png (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/Default@2x.png (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/Info.plist (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/PkgInfo (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/UIButton_custom.png (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/UICatalog (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/blueButton.png (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/bookmarkImage.png (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/bookmarkImageHighlighted.png (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/divider.png (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/en.lproj/AlertsViewController.nib (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/en.lproj/ButtonsViewController.nib (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/en.lproj/ControlsViewController.nib (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/en.lproj/ImagesViewController.nib (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/en.lproj/Localizable.strings (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/en.lproj/MainWindow.nib (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/en.lproj/PickerViewController.nib (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/en.lproj/SearchBarController.nib (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/en.lproj/SegmentViewController.nib (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/en.lproj/TextFieldController.nib (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/en.lproj/TextViewController.nib (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/en.lproj/ToolbarViewController.nib (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/en.lproj/TransitionViewController.nib (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/en.lproj/WebViewController.nib (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/orangeslide.png (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/scene1.jpg (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/scene2.jpg (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/scene3.jpg (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/scene4.jpg (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/scene5.jpg (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/searchBarBackground.png (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/segment_check.png (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/segment_search.png (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/segment_tools.png (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/segmentedBackground.png (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/slider_ball.png (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/toolbarBackground.png (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/whiteButton.png (100%) rename {ruby_lib_ios => ios_tests}/UICatalog.app/yellowslide.png (100%) rename {ruby_lib_ios => ios_tests}/appium.txt (100%) rename {ruby_lib_ios => ios_tests}/lib/format.rb (100%) rename {ruby_lib_ios => ios_tests}/lib/ios/specs/common/element/button.rb (100%) rename {ruby_lib_ios => ios_tests}/lib/ios/specs/common/element/text.rb (100%) rename {ruby_lib_ios => ios_tests}/lib/ios/specs/common/element/window.rb (100%) rename {ruby_lib_ios => ios_tests}/lib/ios/specs/common/helper.rb (100%) rename {ruby_lib_ios => ios_tests}/lib/ios/specs/common/patch.rb (100%) rename {ruby_lib_ios => ios_tests}/lib/ios/specs/common/version.rb (100%) rename {ruby_lib_ios => ios_tests}/lib/ios/specs/driver.rb (100%) rename {ruby_lib_ios => ios_tests}/lib/ios/specs/ios/element/alert.rb (100%) rename {ruby_lib_ios => ios_tests}/lib/ios/specs/ios/element/generic.rb (100%) rename {ruby_lib_ios => ios_tests}/lib/ios/specs/ios/element/textfield.rb (100%) rename {ruby_lib_ios => ios_tests}/lib/ios/specs/ios/helper.rb (100%) rename {ruby_lib_ios => ios_tests}/lib/ios/specs/ios/patch.rb (100%) rename {ruby_lib_ios => ios_tests}/lib/run.rb (100%) rename {ruby_lib_ios => ios_tests}/readme.md (100%) rename {ruby_lib_ios => ios_tests}/upload/sauce_storage.rb (100%) rename {ruby_lib_ios => ios_tests}/upload/upload.rb (100%) diff --git a/ruby_lib_android/Gemfile b/android_tests/Gemfile similarity index 100% rename from ruby_lib_android/Gemfile rename to android_tests/Gemfile diff --git a/ruby_lib_android/LICENSE-2.0.txt b/android_tests/LICENSE-2.0.txt similarity index 100% rename from ruby_lib_android/LICENSE-2.0.txt rename to android_tests/LICENSE-2.0.txt diff --git a/ruby_lib_android/Rakefile b/android_tests/Rakefile similarity index 100% rename from ruby_lib_android/Rakefile rename to android_tests/Rakefile diff --git a/ruby_lib_android/api.apk b/android_tests/api.apk similarity index 100% rename from ruby_lib_android/api.apk rename to android_tests/api.apk diff --git a/ruby_lib_android/appium.txt b/android_tests/appium.txt similarity index 100% rename from ruby_lib_android/appium.txt rename to android_tests/appium.txt diff --git a/ruby_lib_android/lib/android/specs/android/dynamic.rb b/android_tests/lib/android/specs/android/dynamic.rb similarity index 100% rename from ruby_lib_android/lib/android/specs/android/dynamic.rb rename to android_tests/lib/android/specs/android/dynamic.rb diff --git a/ruby_lib_android/lib/android/specs/android/element/alert.rb b/android_tests/lib/android/specs/android/element/alert.rb similarity index 100% rename from ruby_lib_android/lib/android/specs/android/element/alert.rb rename to android_tests/lib/android/specs/android/element/alert.rb diff --git a/ruby_lib_android/lib/android/specs/android/element/generic.rb b/android_tests/lib/android/specs/android/element/generic.rb similarity index 100% rename from ruby_lib_android/lib/android/specs/android/element/generic.rb rename to android_tests/lib/android/specs/android/element/generic.rb diff --git a/ruby_lib_android/lib/android/specs/android/element/textfield.rb b/android_tests/lib/android/specs/android/element/textfield.rb similarity index 100% rename from ruby_lib_android/lib/android/specs/android/element/textfield.rb rename to android_tests/lib/android/specs/android/element/textfield.rb diff --git a/ruby_lib_android/lib/android/specs/android/helper.rb b/android_tests/lib/android/specs/android/helper.rb similarity index 100% rename from ruby_lib_android/lib/android/specs/android/helper.rb rename to android_tests/lib/android/specs/android/helper.rb diff --git a/ruby_lib_android/lib/android/specs/android/patch.rb b/android_tests/lib/android/specs/android/patch.rb similarity index 100% rename from ruby_lib_android/lib/android/specs/android/patch.rb rename to android_tests/lib/android/specs/android/patch.rb diff --git a/ruby_lib_android/lib/android/specs/common/element/button.rb b/android_tests/lib/android/specs/common/element/button.rb similarity index 100% rename from ruby_lib_android/lib/android/specs/common/element/button.rb rename to android_tests/lib/android/specs/common/element/button.rb diff --git a/ruby_lib_android/lib/android/specs/common/element/text.rb b/android_tests/lib/android/specs/common/element/text.rb similarity index 100% rename from ruby_lib_android/lib/android/specs/common/element/text.rb rename to android_tests/lib/android/specs/common/element/text.rb diff --git a/ruby_lib_android/lib/android/specs/common/element/window.rb b/android_tests/lib/android/specs/common/element/window.rb similarity index 100% rename from ruby_lib_android/lib/android/specs/common/element/window.rb rename to android_tests/lib/android/specs/common/element/window.rb diff --git a/ruby_lib_android/lib/android/specs/common/helper.rb b/android_tests/lib/android/specs/common/helper.rb similarity index 100% rename from ruby_lib_android/lib/android/specs/common/helper.rb rename to android_tests/lib/android/specs/common/helper.rb diff --git a/ruby_lib_android/lib/android/specs/common/patch.rb b/android_tests/lib/android/specs/common/patch.rb similarity index 100% rename from ruby_lib_android/lib/android/specs/common/patch.rb rename to android_tests/lib/android/specs/common/patch.rb diff --git a/ruby_lib_android/lib/android/specs/common/version.rb b/android_tests/lib/android/specs/common/version.rb similarity index 100% rename from ruby_lib_android/lib/android/specs/common/version.rb rename to android_tests/lib/android/specs/common/version.rb diff --git a/ruby_lib_android/lib/android/specs/driver.rb b/android_tests/lib/android/specs/driver.rb similarity index 100% rename from ruby_lib_android/lib/android/specs/driver.rb rename to android_tests/lib/android/specs/driver.rb diff --git a/ruby_lib_android/lib/format.rb b/android_tests/lib/format.rb similarity index 100% rename from ruby_lib_android/lib/format.rb rename to android_tests/lib/format.rb diff --git a/ruby_lib_android/lib/run.rb b/android_tests/lib/run.rb similarity index 100% rename from ruby_lib_android/lib/run.rb rename to android_tests/lib/run.rb diff --git a/ruby_lib_android/readme.md b/android_tests/readme.md similarity index 100% rename from ruby_lib_android/readme.md rename to android_tests/readme.md diff --git a/ruby_lib_android/selendroid/appium.txt b/android_tests/selendroid/appium.txt similarity index 100% rename from ruby_lib_android/selendroid/appium.txt rename to android_tests/selendroid/appium.txt diff --git a/ruby_lib_ios/Gemfile b/ios_tests/Gemfile similarity index 100% rename from ruby_lib_ios/Gemfile rename to ios_tests/Gemfile diff --git a/ruby_lib_ios/LICENSE-2.0.txt b/ios_tests/LICENSE-2.0.txt similarity index 100% rename from ruby_lib_ios/LICENSE-2.0.txt rename to ios_tests/LICENSE-2.0.txt diff --git a/ruby_lib_ios/Rakefile b/ios_tests/Rakefile similarity index 100% rename from ruby_lib_ios/Rakefile rename to ios_tests/Rakefile diff --git a/ruby_lib_ios/UICatalog.app.zip b/ios_tests/UICatalog.app.zip similarity index 100% rename from ruby_lib_ios/UICatalog.app.zip rename to ios_tests/UICatalog.app.zip diff --git a/ruby_lib_ios/UICatalog.app/12-6AM.png b/ios_tests/UICatalog.app/12-6AM.png similarity index 100% rename from ruby_lib_ios/UICatalog.app/12-6AM.png rename to ios_tests/UICatalog.app/12-6AM.png diff --git a/ruby_lib_ios/UICatalog.app/12-6PM.png b/ios_tests/UICatalog.app/12-6PM.png similarity index 100% rename from ruby_lib_ios/UICatalog.app/12-6PM.png rename to ios_tests/UICatalog.app/12-6PM.png diff --git a/ruby_lib_ios/UICatalog.app/6-12AM.png b/ios_tests/UICatalog.app/6-12AM.png similarity index 100% rename from ruby_lib_ios/UICatalog.app/6-12AM.png rename to ios_tests/UICatalog.app/6-12AM.png diff --git a/ruby_lib_ios/UICatalog.app/6-12PM.png b/ios_tests/UICatalog.app/6-12PM.png similarity index 100% rename from ruby_lib_ios/UICatalog.app/6-12PM.png rename to ios_tests/UICatalog.app/6-12PM.png diff --git a/ruby_lib_ios/UICatalog.app/Default-568h@2x.png b/ios_tests/UICatalog.app/Default-568h@2x.png similarity index 100% rename from ruby_lib_ios/UICatalog.app/Default-568h@2x.png rename to ios_tests/UICatalog.app/Default-568h@2x.png diff --git a/ruby_lib_ios/UICatalog.app/Default@2x.png b/ios_tests/UICatalog.app/Default@2x.png similarity index 100% rename from ruby_lib_ios/UICatalog.app/Default@2x.png rename to ios_tests/UICatalog.app/Default@2x.png diff --git a/ruby_lib_ios/UICatalog.app/Info.plist b/ios_tests/UICatalog.app/Info.plist similarity index 100% rename from ruby_lib_ios/UICatalog.app/Info.plist rename to ios_tests/UICatalog.app/Info.plist diff --git a/ruby_lib_ios/UICatalog.app/PkgInfo b/ios_tests/UICatalog.app/PkgInfo similarity index 100% rename from ruby_lib_ios/UICatalog.app/PkgInfo rename to ios_tests/UICatalog.app/PkgInfo diff --git a/ruby_lib_ios/UICatalog.app/UIButton_custom.png b/ios_tests/UICatalog.app/UIButton_custom.png similarity index 100% rename from ruby_lib_ios/UICatalog.app/UIButton_custom.png rename to ios_tests/UICatalog.app/UIButton_custom.png diff --git a/ruby_lib_ios/UICatalog.app/UICatalog b/ios_tests/UICatalog.app/UICatalog similarity index 100% rename from ruby_lib_ios/UICatalog.app/UICatalog rename to ios_tests/UICatalog.app/UICatalog diff --git a/ruby_lib_ios/UICatalog.app/blueButton.png b/ios_tests/UICatalog.app/blueButton.png similarity index 100% rename from ruby_lib_ios/UICatalog.app/blueButton.png rename to ios_tests/UICatalog.app/blueButton.png diff --git a/ruby_lib_ios/UICatalog.app/bookmarkImage.png b/ios_tests/UICatalog.app/bookmarkImage.png similarity index 100% rename from ruby_lib_ios/UICatalog.app/bookmarkImage.png rename to ios_tests/UICatalog.app/bookmarkImage.png diff --git a/ruby_lib_ios/UICatalog.app/bookmarkImageHighlighted.png b/ios_tests/UICatalog.app/bookmarkImageHighlighted.png similarity index 100% rename from ruby_lib_ios/UICatalog.app/bookmarkImageHighlighted.png rename to ios_tests/UICatalog.app/bookmarkImageHighlighted.png diff --git a/ruby_lib_ios/UICatalog.app/divider.png b/ios_tests/UICatalog.app/divider.png similarity index 100% rename from ruby_lib_ios/UICatalog.app/divider.png rename to ios_tests/UICatalog.app/divider.png diff --git a/ruby_lib_ios/UICatalog.app/en.lproj/AlertsViewController.nib b/ios_tests/UICatalog.app/en.lproj/AlertsViewController.nib similarity index 100% rename from ruby_lib_ios/UICatalog.app/en.lproj/AlertsViewController.nib rename to ios_tests/UICatalog.app/en.lproj/AlertsViewController.nib diff --git a/ruby_lib_ios/UICatalog.app/en.lproj/ButtonsViewController.nib b/ios_tests/UICatalog.app/en.lproj/ButtonsViewController.nib similarity index 100% rename from ruby_lib_ios/UICatalog.app/en.lproj/ButtonsViewController.nib rename to ios_tests/UICatalog.app/en.lproj/ButtonsViewController.nib diff --git a/ruby_lib_ios/UICatalog.app/en.lproj/ControlsViewController.nib b/ios_tests/UICatalog.app/en.lproj/ControlsViewController.nib similarity index 100% rename from ruby_lib_ios/UICatalog.app/en.lproj/ControlsViewController.nib rename to ios_tests/UICatalog.app/en.lproj/ControlsViewController.nib diff --git a/ruby_lib_ios/UICatalog.app/en.lproj/ImagesViewController.nib b/ios_tests/UICatalog.app/en.lproj/ImagesViewController.nib similarity index 100% rename from ruby_lib_ios/UICatalog.app/en.lproj/ImagesViewController.nib rename to ios_tests/UICatalog.app/en.lproj/ImagesViewController.nib diff --git a/ruby_lib_ios/UICatalog.app/en.lproj/Localizable.strings b/ios_tests/UICatalog.app/en.lproj/Localizable.strings similarity index 100% rename from ruby_lib_ios/UICatalog.app/en.lproj/Localizable.strings rename to ios_tests/UICatalog.app/en.lproj/Localizable.strings diff --git a/ruby_lib_ios/UICatalog.app/en.lproj/MainWindow.nib b/ios_tests/UICatalog.app/en.lproj/MainWindow.nib similarity index 100% rename from ruby_lib_ios/UICatalog.app/en.lproj/MainWindow.nib rename to ios_tests/UICatalog.app/en.lproj/MainWindow.nib diff --git a/ruby_lib_ios/UICatalog.app/en.lproj/PickerViewController.nib b/ios_tests/UICatalog.app/en.lproj/PickerViewController.nib similarity index 100% rename from ruby_lib_ios/UICatalog.app/en.lproj/PickerViewController.nib rename to ios_tests/UICatalog.app/en.lproj/PickerViewController.nib diff --git a/ruby_lib_ios/UICatalog.app/en.lproj/SearchBarController.nib b/ios_tests/UICatalog.app/en.lproj/SearchBarController.nib similarity index 100% rename from ruby_lib_ios/UICatalog.app/en.lproj/SearchBarController.nib rename to ios_tests/UICatalog.app/en.lproj/SearchBarController.nib diff --git a/ruby_lib_ios/UICatalog.app/en.lproj/SegmentViewController.nib b/ios_tests/UICatalog.app/en.lproj/SegmentViewController.nib similarity index 100% rename from ruby_lib_ios/UICatalog.app/en.lproj/SegmentViewController.nib rename to ios_tests/UICatalog.app/en.lproj/SegmentViewController.nib diff --git a/ruby_lib_ios/UICatalog.app/en.lproj/TextFieldController.nib b/ios_tests/UICatalog.app/en.lproj/TextFieldController.nib similarity index 100% rename from ruby_lib_ios/UICatalog.app/en.lproj/TextFieldController.nib rename to ios_tests/UICatalog.app/en.lproj/TextFieldController.nib diff --git a/ruby_lib_ios/UICatalog.app/en.lproj/TextViewController.nib b/ios_tests/UICatalog.app/en.lproj/TextViewController.nib similarity index 100% rename from ruby_lib_ios/UICatalog.app/en.lproj/TextViewController.nib rename to ios_tests/UICatalog.app/en.lproj/TextViewController.nib diff --git a/ruby_lib_ios/UICatalog.app/en.lproj/ToolbarViewController.nib b/ios_tests/UICatalog.app/en.lproj/ToolbarViewController.nib similarity index 100% rename from ruby_lib_ios/UICatalog.app/en.lproj/ToolbarViewController.nib rename to ios_tests/UICatalog.app/en.lproj/ToolbarViewController.nib diff --git a/ruby_lib_ios/UICatalog.app/en.lproj/TransitionViewController.nib b/ios_tests/UICatalog.app/en.lproj/TransitionViewController.nib similarity index 100% rename from ruby_lib_ios/UICatalog.app/en.lproj/TransitionViewController.nib rename to ios_tests/UICatalog.app/en.lproj/TransitionViewController.nib diff --git a/ruby_lib_ios/UICatalog.app/en.lproj/WebViewController.nib b/ios_tests/UICatalog.app/en.lproj/WebViewController.nib similarity index 100% rename from ruby_lib_ios/UICatalog.app/en.lproj/WebViewController.nib rename to ios_tests/UICatalog.app/en.lproj/WebViewController.nib diff --git a/ruby_lib_ios/UICatalog.app/orangeslide.png b/ios_tests/UICatalog.app/orangeslide.png similarity index 100% rename from ruby_lib_ios/UICatalog.app/orangeslide.png rename to ios_tests/UICatalog.app/orangeslide.png diff --git a/ruby_lib_ios/UICatalog.app/scene1.jpg b/ios_tests/UICatalog.app/scene1.jpg similarity index 100% rename from ruby_lib_ios/UICatalog.app/scene1.jpg rename to ios_tests/UICatalog.app/scene1.jpg diff --git a/ruby_lib_ios/UICatalog.app/scene2.jpg b/ios_tests/UICatalog.app/scene2.jpg similarity index 100% rename from ruby_lib_ios/UICatalog.app/scene2.jpg rename to ios_tests/UICatalog.app/scene2.jpg diff --git a/ruby_lib_ios/UICatalog.app/scene3.jpg b/ios_tests/UICatalog.app/scene3.jpg similarity index 100% rename from ruby_lib_ios/UICatalog.app/scene3.jpg rename to ios_tests/UICatalog.app/scene3.jpg diff --git a/ruby_lib_ios/UICatalog.app/scene4.jpg b/ios_tests/UICatalog.app/scene4.jpg similarity index 100% rename from ruby_lib_ios/UICatalog.app/scene4.jpg rename to ios_tests/UICatalog.app/scene4.jpg diff --git a/ruby_lib_ios/UICatalog.app/scene5.jpg b/ios_tests/UICatalog.app/scene5.jpg similarity index 100% rename from ruby_lib_ios/UICatalog.app/scene5.jpg rename to ios_tests/UICatalog.app/scene5.jpg diff --git a/ruby_lib_ios/UICatalog.app/searchBarBackground.png b/ios_tests/UICatalog.app/searchBarBackground.png similarity index 100% rename from ruby_lib_ios/UICatalog.app/searchBarBackground.png rename to ios_tests/UICatalog.app/searchBarBackground.png diff --git a/ruby_lib_ios/UICatalog.app/segment_check.png b/ios_tests/UICatalog.app/segment_check.png similarity index 100% rename from ruby_lib_ios/UICatalog.app/segment_check.png rename to ios_tests/UICatalog.app/segment_check.png diff --git a/ruby_lib_ios/UICatalog.app/segment_search.png b/ios_tests/UICatalog.app/segment_search.png similarity index 100% rename from ruby_lib_ios/UICatalog.app/segment_search.png rename to ios_tests/UICatalog.app/segment_search.png diff --git a/ruby_lib_ios/UICatalog.app/segment_tools.png b/ios_tests/UICatalog.app/segment_tools.png similarity index 100% rename from ruby_lib_ios/UICatalog.app/segment_tools.png rename to ios_tests/UICatalog.app/segment_tools.png diff --git a/ruby_lib_ios/UICatalog.app/segmentedBackground.png b/ios_tests/UICatalog.app/segmentedBackground.png similarity index 100% rename from ruby_lib_ios/UICatalog.app/segmentedBackground.png rename to ios_tests/UICatalog.app/segmentedBackground.png diff --git a/ruby_lib_ios/UICatalog.app/slider_ball.png b/ios_tests/UICatalog.app/slider_ball.png similarity index 100% rename from ruby_lib_ios/UICatalog.app/slider_ball.png rename to ios_tests/UICatalog.app/slider_ball.png diff --git a/ruby_lib_ios/UICatalog.app/toolbarBackground.png b/ios_tests/UICatalog.app/toolbarBackground.png similarity index 100% rename from ruby_lib_ios/UICatalog.app/toolbarBackground.png rename to ios_tests/UICatalog.app/toolbarBackground.png diff --git a/ruby_lib_ios/UICatalog.app/whiteButton.png b/ios_tests/UICatalog.app/whiteButton.png similarity index 100% rename from ruby_lib_ios/UICatalog.app/whiteButton.png rename to ios_tests/UICatalog.app/whiteButton.png diff --git a/ruby_lib_ios/UICatalog.app/yellowslide.png b/ios_tests/UICatalog.app/yellowslide.png similarity index 100% rename from ruby_lib_ios/UICatalog.app/yellowslide.png rename to ios_tests/UICatalog.app/yellowslide.png diff --git a/ruby_lib_ios/appium.txt b/ios_tests/appium.txt similarity index 100% rename from ruby_lib_ios/appium.txt rename to ios_tests/appium.txt diff --git a/ruby_lib_ios/lib/format.rb b/ios_tests/lib/format.rb similarity index 100% rename from ruby_lib_ios/lib/format.rb rename to ios_tests/lib/format.rb diff --git a/ruby_lib_ios/lib/ios/specs/common/element/button.rb b/ios_tests/lib/ios/specs/common/element/button.rb similarity index 100% rename from ruby_lib_ios/lib/ios/specs/common/element/button.rb rename to ios_tests/lib/ios/specs/common/element/button.rb diff --git a/ruby_lib_ios/lib/ios/specs/common/element/text.rb b/ios_tests/lib/ios/specs/common/element/text.rb similarity index 100% rename from ruby_lib_ios/lib/ios/specs/common/element/text.rb rename to ios_tests/lib/ios/specs/common/element/text.rb diff --git a/ruby_lib_ios/lib/ios/specs/common/element/window.rb b/ios_tests/lib/ios/specs/common/element/window.rb similarity index 100% rename from ruby_lib_ios/lib/ios/specs/common/element/window.rb rename to ios_tests/lib/ios/specs/common/element/window.rb diff --git a/ruby_lib_ios/lib/ios/specs/common/helper.rb b/ios_tests/lib/ios/specs/common/helper.rb similarity index 100% rename from ruby_lib_ios/lib/ios/specs/common/helper.rb rename to ios_tests/lib/ios/specs/common/helper.rb diff --git a/ruby_lib_ios/lib/ios/specs/common/patch.rb b/ios_tests/lib/ios/specs/common/patch.rb similarity index 100% rename from ruby_lib_ios/lib/ios/specs/common/patch.rb rename to ios_tests/lib/ios/specs/common/patch.rb diff --git a/ruby_lib_ios/lib/ios/specs/common/version.rb b/ios_tests/lib/ios/specs/common/version.rb similarity index 100% rename from ruby_lib_ios/lib/ios/specs/common/version.rb rename to ios_tests/lib/ios/specs/common/version.rb diff --git a/ruby_lib_ios/lib/ios/specs/driver.rb b/ios_tests/lib/ios/specs/driver.rb similarity index 100% rename from ruby_lib_ios/lib/ios/specs/driver.rb rename to ios_tests/lib/ios/specs/driver.rb diff --git a/ruby_lib_ios/lib/ios/specs/ios/element/alert.rb b/ios_tests/lib/ios/specs/ios/element/alert.rb similarity index 100% rename from ruby_lib_ios/lib/ios/specs/ios/element/alert.rb rename to ios_tests/lib/ios/specs/ios/element/alert.rb diff --git a/ruby_lib_ios/lib/ios/specs/ios/element/generic.rb b/ios_tests/lib/ios/specs/ios/element/generic.rb similarity index 100% rename from ruby_lib_ios/lib/ios/specs/ios/element/generic.rb rename to ios_tests/lib/ios/specs/ios/element/generic.rb diff --git a/ruby_lib_ios/lib/ios/specs/ios/element/textfield.rb b/ios_tests/lib/ios/specs/ios/element/textfield.rb similarity index 100% rename from ruby_lib_ios/lib/ios/specs/ios/element/textfield.rb rename to ios_tests/lib/ios/specs/ios/element/textfield.rb diff --git a/ruby_lib_ios/lib/ios/specs/ios/helper.rb b/ios_tests/lib/ios/specs/ios/helper.rb similarity index 100% rename from ruby_lib_ios/lib/ios/specs/ios/helper.rb rename to ios_tests/lib/ios/specs/ios/helper.rb diff --git a/ruby_lib_ios/lib/ios/specs/ios/patch.rb b/ios_tests/lib/ios/specs/ios/patch.rb similarity index 100% rename from ruby_lib_ios/lib/ios/specs/ios/patch.rb rename to ios_tests/lib/ios/specs/ios/patch.rb diff --git a/ruby_lib_ios/lib/run.rb b/ios_tests/lib/run.rb similarity index 100% rename from ruby_lib_ios/lib/run.rb rename to ios_tests/lib/run.rb diff --git a/ruby_lib_ios/readme.md b/ios_tests/readme.md similarity index 100% rename from ruby_lib_ios/readme.md rename to ios_tests/readme.md diff --git a/ruby_lib_ios/upload/sauce_storage.rb b/ios_tests/upload/sauce_storage.rb similarity index 100% rename from ruby_lib_ios/upload/sauce_storage.rb rename to ios_tests/upload/sauce_storage.rb diff --git a/ruby_lib_ios/upload/upload.rb b/ios_tests/upload/upload.rb similarity index 100% rename from ruby_lib_ios/upload/upload.rb rename to ios_tests/upload/upload.rb diff --git a/lib/appium_lib/driver.rb b/lib/appium_lib/driver.rb index 41d2fd57..56a72b76 100644 --- a/lib/appium_lib/driver.rb +++ b/lib/appium_lib/driver.rb @@ -66,7 +66,7 @@ def self.load_appium_txt opts={} toml_exists = File.exists? toml puts "Exists? #{toml_exists}" if verbose - raise "toml doesn't exist ##{toml}" unless toml_exists + raise "toml doesn't exist #{toml}" unless toml_exists require 'toml' puts "Loading #{toml}" if verbose