run_loop 2.6.1 → 2.6.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/lib/run_loop/core.rb +5 -1
- data/lib/run_loop/device_agent/Frameworks.zip +0 -0
- data/lib/run_loop/device_agent/bin/iOSDeviceManager +0 -0
- data/lib/run_loop/device_agent/client.rb +1 -1
- data/lib/run_loop/dylib_injector.rb +23 -0
- data/lib/run_loop/http/retriable_client.rb +2 -0
- data/lib/run_loop/version.rb +13 -1
- data/lib/run_loop/xcode.rb +30 -0
- metadata +3 -3
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: d157fb1a0866b6105c1dfef4bd804f772b5f53dc
|
4
|
+
data.tar.gz: 073d5eebb4852b48cd5dc0f9b0d4cc9fa52b61ee
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 95e5a217258365b50639ca76cbc1c4632b497477319df3b006019c40b80438fed4e8d168bdb75e75e7f8776eb275ae2437b8aa582b5c726de5ece39c6964cb54
|
7
|
+
data.tar.gz: b21e59f88359d74e7873d74bc872432d0e95ca6045dbf02868e6771d22effa9856c2fb2ee0da371d48546c79b0dfa412cb01af10fd26868fe6e424e6d10c8ede
|
data/lib/run_loop/core.rb
CHANGED
@@ -320,7 +320,11 @@ Logfile: #{log_file}
|
|
320
320
|
# version.
|
321
321
|
def self.default_simulator(xcode=RunLoop::Xcode.new)
|
322
322
|
|
323
|
-
if xcode.
|
323
|
+
if xcode.version_gte_92?
|
324
|
+
"iPhone 7 (11.2)"
|
325
|
+
elsif xcode.version_gte_91?
|
326
|
+
"iPhone 7 (11.1)"
|
327
|
+
elsif xcode.version_gte_90?
|
324
328
|
"iPhone 7 (11.0)"
|
325
329
|
elsif xcode.version_gte_83?
|
326
330
|
"iPhone 7 (10.3)"
|
Binary file
|
Binary file
|
@@ -506,7 +506,7 @@ INSTANCE METHODS
|
|
506
506
|
# ]
|
507
507
|
# ```
|
508
508
|
#
|
509
|
-
# @see
|
509
|
+
# @see https://developer.apple.com/documentation/xctest/xcuielementtype
|
510
510
|
# @param [Hash] uiquery A hash describing the query.
|
511
511
|
# @return [Array<Hash>] An array of elements matching the `uiquery`.
|
512
512
|
def query(uiquery)
|
@@ -26,6 +26,25 @@ module RunLoop
|
|
26
26
|
:timeout => RunLoop::Environment.ci? ? 40 : 20
|
27
27
|
}
|
28
28
|
|
29
|
+
# Options for controlling dylib injection
|
30
|
+
#
|
31
|
+
# You can override these values if they do not work in your environment.
|
32
|
+
#
|
33
|
+
# For cucumber users, the best place to override would be in your
|
34
|
+
# features/support/env.rb.
|
35
|
+
#
|
36
|
+
# For example:
|
37
|
+
#
|
38
|
+
# RunLoop::DylibInjector::OPTIONS[:injection_delay] = 10.0
|
39
|
+
OPTIONS = {
|
40
|
+
# Starting in Xcode 9, some apps need additional time to launch
|
41
|
+
# completely.
|
42
|
+
#
|
43
|
+
# If lldb interupts the app before it can accept a 'dlopen' command,
|
44
|
+
# the app will never finish launching - even on a retry.
|
45
|
+
injection_delay: RunLoop::Environment.ci? ? 1.0 : 5.0
|
46
|
+
}
|
47
|
+
|
29
48
|
# Extracts the value of :inject_dylib from options Hash.
|
30
49
|
# @param options [Hash] arguments passed to {RunLoop.run}
|
31
50
|
# @return [String, nil] If the options contains :inject_dylibs and it is a
|
@@ -125,6 +144,10 @@ Expected :inject_dylib to be a path to a dylib, but found '#{inject_dylib}'
|
|
125
144
|
end
|
126
145
|
|
127
146
|
def retriable_inject_dylib(options={})
|
147
|
+
delay = OPTIONS[:injection_delay]
|
148
|
+
RunLoop.log_debug("Delaying dylib injection by #{delay} seconds to allow app to finish launching")
|
149
|
+
sleep(delay)
|
150
|
+
|
128
151
|
merged_options = RETRY_OPTIONS.merge(options)
|
129
152
|
|
130
153
|
tries = merged_options[:tries]
|
data/lib/run_loop/version.rb
CHANGED
@@ -1,5 +1,5 @@
|
|
1
1
|
module RunLoop
|
2
|
-
VERSION = "2.6.
|
2
|
+
VERSION = "2.6.2"
|
3
3
|
|
4
4
|
# A model of a software release version that can be used to compare two versions.
|
5
5
|
#
|
@@ -155,6 +155,18 @@ module RunLoop
|
|
155
155
|
Version.compare(self, other) >= 0
|
156
156
|
end
|
157
157
|
|
158
|
+
# Compare version `a` to version `b`.
|
159
|
+
#
|
160
|
+
# @example
|
161
|
+
# compare Version.new(0.10.0), Version.new(0.9.0) => 1
|
162
|
+
# compare Version.new(0.9.0), Version.new(0.10.0) => -1
|
163
|
+
# compare Version.new(0.9.0), Version.new(0.9.0) => 0
|
164
|
+
#
|
165
|
+
# @return [Integer] an integer `(-1, 1)`
|
166
|
+
def <=> (other)
|
167
|
+
Version.compare(self, other)
|
168
|
+
end
|
169
|
+
|
158
170
|
# Compare version `a` to version `b`.
|
159
171
|
#
|
160
172
|
# @example
|
data/lib/run_loop/xcode.rb
CHANGED
@@ -26,6 +26,22 @@ module RunLoop
|
|
26
26
|
to_s
|
27
27
|
end
|
28
28
|
|
29
|
+
# Returns a version instance for Xcode 9.2; used to check for the
|
30
|
+
# availability of features and paths to various items on the filesystem
|
31
|
+
#
|
32
|
+
# @return [RunLoop::Version] 9.2
|
33
|
+
def v92
|
34
|
+
fetch_version(:v92)
|
35
|
+
end
|
36
|
+
|
37
|
+
# Returns a version instance for Xcode 9.1; used to check for the
|
38
|
+
# availability of features and paths to various items on the filesystem
|
39
|
+
#
|
40
|
+
# @return [RunLoop::Version] 9.1
|
41
|
+
def v91
|
42
|
+
fetch_version(:v91)
|
43
|
+
end
|
44
|
+
|
29
45
|
# Returns a version instance for Xcode 9.0; used to check for the
|
30
46
|
# availability of features and paths to various items on the filesystem
|
31
47
|
#
|
@@ -154,6 +170,20 @@ module RunLoop
|
|
154
170
|
fetch_version(:v50)
|
155
171
|
end
|
156
172
|
|
173
|
+
# Is the active Xcode version 9.1 or above?
|
174
|
+
#
|
175
|
+
# @return [Boolean] `true` if the current Xcode version is >= 9.2
|
176
|
+
def version_gte_92?
|
177
|
+
version >= v92
|
178
|
+
end
|
179
|
+
|
180
|
+
# Is the active Xcode version 9.1 or above?
|
181
|
+
#
|
182
|
+
# @return [Boolean] `true` if the current Xcode version is >= 9.1
|
183
|
+
def version_gte_91?
|
184
|
+
version >= v91
|
185
|
+
end
|
186
|
+
|
157
187
|
# Is the active Xcode version 9.0 or above?
|
158
188
|
#
|
159
189
|
# @return [Boolean] `true` if the current Xcode version is >= 9.0
|
metadata
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: run_loop
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 2.6.
|
4
|
+
version: 2.6.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Karl Krukow
|
@@ -9,7 +9,7 @@ authors:
|
|
9
9
|
autorequire:
|
10
10
|
bindir: bin
|
11
11
|
cert_chain: []
|
12
|
-
date: 2017-09
|
12
|
+
date: 2017-11-09 00:00:00.000000000 Z
|
13
13
|
dependencies:
|
14
14
|
- !ruby/object:Gem::Dependency
|
15
15
|
name: json
|
@@ -415,7 +415,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
|
|
415
415
|
version: '0'
|
416
416
|
requirements: []
|
417
417
|
rubyforge_project:
|
418
|
-
rubygems_version: 2.6.
|
418
|
+
rubygems_version: 2.6.14
|
419
419
|
signing_key:
|
420
420
|
specification_version: 4
|
421
421
|
summary: The bridge between Calabash iOS and Xcode command-line tools like instruments
|