run_loop 2.1.3 → 2.1.4

Sign up to get free protection for your applications and to get access to all the features.
Files changed (39) hide show
  1. checksums.yaml +4 -4
  2. data/lib/run_loop.rb +119 -4
  3. data/lib/run_loop/{host_cache.rb → cache.rb} +8 -3
  4. data/lib/run_loop/codesign.rb +3 -3
  5. data/lib/run_loop/core.rb +26 -5
  6. data/lib/run_loop/core_simulator.rb +14 -13
  7. data/lib/run_loop/detect_aut/detect.rb +1 -1
  8. data/lib/run_loop/device.rb +2 -2
  9. data/lib/run_loop/device_agent/Frameworks.zip +0 -0
  10. data/lib/run_loop/device_agent/app/CBX-Runner.app.zip +0 -0
  11. data/lib/run_loop/device_agent/bin/iOSDeviceManager +0 -0
  12. data/lib/run_loop/device_agent/cbxrunner.rb +3 -2
  13. data/lib/run_loop/device_agent/frameworks.rb +7 -13
  14. data/lib/run_loop/device_agent/{xctestctl.rb → ios_device_manager.rb} +36 -24
  15. data/lib/run_loop/device_agent/ipa/CBX-Runner.app.zip +0 -0
  16. data/lib/run_loop/device_agent/launcher.rb +8 -0
  17. data/lib/run_loop/device_agent/xcodebuild.rb +5 -0
  18. data/lib/run_loop/dnssd.rb +148 -0
  19. data/lib/run_loop/dot_dir.rb +1 -1
  20. data/lib/run_loop/dylib_injector.rb +1 -1
  21. data/lib/run_loop/encoding.rb +17 -0
  22. data/lib/run_loop/environment.rb +15 -5
  23. data/lib/run_loop/instruments.rb +2 -2
  24. data/lib/run_loop/language.rb +4 -0
  25. data/lib/run_loop/locale.rb +4 -1
  26. data/lib/run_loop/otool.rb +1 -1
  27. data/lib/run_loop/process_terminator.rb +1 -1
  28. data/lib/run_loop/shell.rb +2 -2
  29. data/lib/run_loop/sim_control.rb +5 -5
  30. data/lib/run_loop/simctl.rb +2 -2
  31. data/lib/run_loop/strings.rb +1 -1
  32. data/lib/run_loop/version.rb +1 -1
  33. data/lib/run_loop/xcode.rb +15 -0
  34. data/lib/run_loop/xcrun.rb +7 -3
  35. data/lib/run_loop/xcuitest.rb +155 -68
  36. metadata +41 -21
  37. data/lib/run_loop/cache/cache.rb +0 -68
  38. data/lib/run_loop/device_agent/bin/xctestctl +0 -0
  39. data/lib/run_loop/device_agent/frameworks/Frameworks.zip +0 -0
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: run_loop
3
3
  version: !ruby/object:Gem::Version
4
- version: 2.1.3
4
+ version: 2.1.4
5
5
  platform: ruby
6
6
  authors:
7
7
  - Karl Krukow
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2016-06-06 00:00:00.000000000 Z
11
+ date: 2016-07-21 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: json
@@ -100,6 +100,40 @@ dependencies:
100
100
  - - "~>"
101
101
  - !ruby/object:Gem::Version
102
102
  version: '2.6'
103
+ - !ruby/object:Gem::Dependency
104
+ name: dnssd
105
+ requirement: !ruby/object:Gem::Requirement
106
+ requirements:
107
+ - - '='
108
+ - !ruby/object:Gem::Version
109
+ version: '2.0'
110
+ type: :runtime
111
+ prerelease: false
112
+ version_requirements: !ruby/object:Gem::Requirement
113
+ requirements:
114
+ - - '='
115
+ - !ruby/object:Gem::Version
116
+ version: '2.0'
117
+ - !ruby/object:Gem::Dependency
118
+ name: i18n
119
+ requirement: !ruby/object:Gem::Requirement
120
+ requirements:
121
+ - - ">="
122
+ - !ruby/object:Gem::Version
123
+ version: 0.7.0
124
+ - - "<"
125
+ - !ruby/object:Gem::Version
126
+ version: '1.0'
127
+ type: :runtime
128
+ prerelease: false
129
+ version_requirements: !ruby/object:Gem::Requirement
130
+ requirements:
131
+ - - ">="
132
+ - !ruby/object:Gem::Version
133
+ version: 0.7.0
134
+ - - "<"
135
+ - !ruby/object:Gem::Version
136
+ version: '1.0'
103
137
  - !ruby/object:Gem::Dependency
104
138
  name: rspec_junit_formatter
105
139
  requirement: !ruby/object:Gem::Requirement
@@ -142,20 +176,6 @@ dependencies:
142
176
  - - "~>"
143
177
  - !ruby/object:Gem::Version
144
178
  version: '1.6'
145
- - !ruby/object:Gem::Dependency
146
- name: travis
147
- requirement: !ruby/object:Gem::Requirement
148
- requirements:
149
- - - "~>"
150
- - !ruby/object:Gem::Version
151
- version: '1.8'
152
- type: :development
153
- prerelease: false
154
- version_requirements: !ruby/object:Gem::Requirement
155
- requirements:
156
- - - "~>"
157
- - !ruby/object:Gem::Version
158
- version: '1.8'
159
179
  - !ruby/object:Gem::Dependency
160
180
  name: rspec
161
181
  requirement: !ruby/object:Gem::Requirement
@@ -303,7 +323,7 @@ files:
303
323
  - lib/run_loop.rb
304
324
  - lib/run_loop/abstract.rb
305
325
  - lib/run_loop/app.rb
306
- - lib/run_loop/cache/cache.rb
326
+ - lib/run_loop/cache.rb
307
327
  - lib/run_loop/cli/cli.rb
308
328
  - lib/run_loop/cli/codesign.rb
309
329
  - lib/run_loop/cli/errors.rb
@@ -318,22 +338,22 @@ files:
318
338
  - lib/run_loop/detect_aut/xamarin_studio.rb
319
339
  - lib/run_loop/detect_aut/xcode.rb
320
340
  - lib/run_loop/device.rb
341
+ - lib/run_loop/device_agent/Frameworks.zip
321
342
  - lib/run_loop/device_agent/app/CBX-Runner.app.zip
322
- - lib/run_loop/device_agent/bin/xctestctl
343
+ - lib/run_loop/device_agent/bin/iOSDeviceManager
323
344
  - lib/run_loop/device_agent/cbxrunner.rb
324
345
  - lib/run_loop/device_agent/frameworks.rb
325
- - lib/run_loop/device_agent/frameworks/Frameworks.zip
346
+ - lib/run_loop/device_agent/ios_device_manager.rb
326
347
  - lib/run_loop/device_agent/ipa/CBX-Runner.app.zip
327
348
  - lib/run_loop/device_agent/launcher.rb
328
349
  - lib/run_loop/device_agent/xcodebuild.rb
329
- - lib/run_loop/device_agent/xctestctl.rb
330
350
  - lib/run_loop/directory.rb
351
+ - lib/run_loop/dnssd.rb
331
352
  - lib/run_loop/dot_dir.rb
332
353
  - lib/run_loop/dylib_injector.rb
333
354
  - lib/run_loop/encoding.rb
334
355
  - lib/run_loop/environment.rb
335
356
  - lib/run_loop/fifo.rb
336
- - lib/run_loop/host_cache.rb
337
357
  - lib/run_loop/http/error.rb
338
358
  - lib/run_loop/http/request.rb
339
359
  - lib/run_loop/http/retriable_client.rb
@@ -1,68 +0,0 @@
1
- module RunLoop
2
-
3
- # @!visibility private
4
- # A class for managing an on-disk cache.
5
- class Cache
6
-
7
- require 'fileutils'
8
-
9
- def initialize(path)
10
- @path = path
11
- end
12
-
13
- def clear
14
- raise NotImplementedError, 'Subclasses must implement #clear'
15
- end
16
-
17
- def refresh
18
- raise NotImplementedError, 'Subclasses must implement #refresh'
19
- end
20
-
21
- # Reads the current cache.
22
- # @return [Hash] A hash representation of the cache on disk.
23
- def read
24
- if File.exist? path
25
- File.open(path) do |file|
26
- Marshal.load(file)
27
- end
28
- else
29
- write({})
30
- end
31
- end
32
-
33
- private
34
-
35
- attr_reader :path
36
-
37
- # @!visibility private
38
- #
39
- # Writes `hash` as a serial object. The existing data is overwritten.
40
- #
41
- # @param [Hash] hash The hash to write.
42
- # @raise [ArgumentError] The `hash` parameter must not be nil and it must
43
- # be a Hash.
44
- # @raise [TypeError] If the hash contains objects that cannot be written
45
- # by Marshal.dump.
46
- #
47
- # @return [Hash] Returns the `hash` argument.
48
- def write(hash)
49
- if hash.nil?
50
- raise ArgumentError, 'Expected the hash parameter to be non-nil'
51
- end
52
-
53
- unless hash.is_a?(Hash)
54
- raise ArgumentError, "Expected #{hash} to a Hash, but it is a #{hash.class}"
55
- end
56
-
57
- directory = File.dirname(path)
58
- unless File.exist?(directory)
59
- FileUtils.mkdir_p(directory)
60
- end
61
-
62
- File.open(path, 'w') do |file|
63
- Marshal.dump(hash, file)
64
- end
65
- hash
66
- end
67
- end
68
- end