appium_lib 2.1.0 → 3.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/android_tests/lib/android/specs/android/element/button.rb +2 -2
- data/android_tests/lib/android/specs/android/helper.rb +5 -6
- data/android_tests/lib/android/specs/common/device.rb +10 -13
- data/android_tests/lib/android/specs/common/helper.rb +0 -14
- data/android_tests/lib/android/specs/driver.rb +11 -3
- data/android_tests/lib/run.rb +1 -0
- data/docs/android_docs.md +159 -239
- data/docs/ios_docs.md +147 -147
- data/lib/appium_lib/android/dynamic.rb +3 -0
- data/lib/appium_lib/android/element/button.rb +39 -16
- data/lib/appium_lib/android/element/generic.rb +4 -4
- data/lib/appium_lib/android/element/text.rb +4 -4
- data/lib/appium_lib/android/element/textfield.rb +4 -4
- data/lib/appium_lib/android/helper.rb +77 -106
- data/lib/appium_lib/common/patch.rb +1 -1
- data/lib/appium_lib/common/version.rb +2 -2
- data/lib/appium_lib/device/device.rb +13 -6
- data/release_notes.md +9 -0
- metadata +2 -2
@@ -94,7 +94,7 @@ def patch_webdriver_bridge
|
|
94
94
|
# For complex_find, we pass a whole array
|
95
95
|
if command_hash.kind_of? Array
|
96
96
|
print_command[:args] = [command_hash.clone]
|
97
|
-
print_command[:script] = '
|
97
|
+
print_command[:script] = 'complex_find' if command == :complex_find
|
98
98
|
else
|
99
99
|
print_command = command_hash.clone
|
100
100
|
end
|
@@ -1,5 +1,5 @@
|
|
1
1
|
module Appium
|
2
2
|
# Version and Date are defined on the 'Appium' module, not 'Appium::Common'
|
3
|
-
VERSION = '
|
4
|
-
DATE = '2014-05-
|
3
|
+
VERSION = '3.0.0' unless defined? ::Appium::VERSION
|
4
|
+
DATE = '2014-05-30' unless defined? ::Appium::DATE
|
5
5
|
end
|
@@ -163,18 +163,25 @@ module Appium
|
|
163
163
|
|
164
164
|
add_endpoint_method(:complex_find, 'session/:session_id/appium/app/complex_find') do
|
165
165
|
def complex_find(opts)
|
166
|
-
|
166
|
+
# allow: complex_find([[[3, 'app']]])
|
167
|
+
opts = { selectors: opts } if opts.is_a?(Array)
|
168
|
+
mode = opts.fetch :mode, false # mode can be 'all' or 'scroll'
|
167
169
|
selectors = opts.fetch :selectors, false
|
168
170
|
raise 'Complex find must have selectors' unless selectors
|
169
|
-
selectors.insert(0, mode) if mode
|
171
|
+
selectors = selectors.dup.insert(0, mode) if mode # must dupe before insert
|
170
172
|
|
171
173
|
ids = execute :complex_find, {}, selectors
|
174
|
+
ids = [ids] unless ids.is_a? Array # wrap single result in an array
|
172
175
|
|
173
|
-
|
174
|
-
|
175
|
-
|
176
|
-
|
176
|
+
# mode can be set directly in the selectors
|
177
|
+
find_all = mode == 'all' || selectors.first == 'all'
|
178
|
+
|
179
|
+
result = ids.map do |id|
|
180
|
+
resolved_id = element_id_from(id)
|
181
|
+
Selenium::WebDriver::Element.new self, resolved_id
|
177
182
|
end
|
183
|
+
# when not finding all, don't return an array
|
184
|
+
return find_all ? result : result.first
|
178
185
|
end
|
179
186
|
end
|
180
187
|
|
data/release_notes.md
CHANGED
@@ -1,3 +1,12 @@
|
|
1
|
+
#### v3.0.0 2014-05-30
|
2
|
+
|
3
|
+
- [77d64af](https://github.com/appium/ruby_lib/commit/77d64af57b0e6a828c5d61008c444518e6597e4b) Release 3.0.0
|
4
|
+
- [86f1655](https://github.com/appium/ruby_lib/commit/86f1655d51ee74ec32e720ff285c30175283d4fd) Rename mobile find to complex_find
|
5
|
+
- [109139b](https://github.com/appium/ruby_lib/commit/109139bd6ff664e020609a5828ab755c9f6dbf2e) Merge pull request #207 from appium/no_xpath
|
6
|
+
- [682797d](https://github.com/appium/ruby_lib/commit/682797d252a040ffcc225a43491842c3e0d6e2ad) Use uiselector instead of xpath
|
7
|
+
- [0c51bca](https://github.com/appium/ruby_lib/commit/0c51bcab548826d125b9f90418079fc8af72071a) Update complex find constants
|
8
|
+
|
9
|
+
|
1
10
|
#### v2.1.0 2014-05-21
|
2
11
|
|
3
12
|
- [f0db091](https://github.com/appium/ruby_lib/commit/f0db0910ea077e04329d3e0cafb434f829760abb) Release 2.1.0
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: appium_lib
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version:
|
4
|
+
version: 3.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- code@bootstraponline.com
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-05-
|
11
|
+
date: 2014-05-30 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: selenium-webdriver
|