fastlane-plugin-automated_test_emulator_run 0.3 → 0.3.1

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 CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 8c444151e3e03b3d479e1ff688f0d16f314d53e5
4
- data.tar.gz: 6214b83edc38e37f29cf4406428456afe5cd0f53
3
+ metadata.gz: 69c2fba9cbbf17e081d4f6252dcf4bcd6a8ce5c4
4
+ data.tar.gz: 2512681f130be981064a8f81b592384f2181dbda
5
5
  SHA512:
6
- metadata.gz: c36d9a80a04a7bbc3519e07e6ae958ff12a64e76681da3fb82900453afd74e3a29e94ce54c6fd34f226084feea2e17b574b191d8333d2ee6238bb0956582e5c6
7
- data.tar.gz: 79db7ef0f72fc2fad1501212b5a2ad3d019403341e86f9b620f95c91310fea0dcf07a4f1e36cc066fb136d06e68e799936ad2d4561a5efe6a222aa1965e6d6a5
6
+ metadata.gz: d9d45960975def2bf10d2b9139d98480399ec3933377afbe97f53c0e2badb2833b429a1c6d7ff15e147ee86748cb492ab477db35c668f96a8327d9602ea19b4d
7
+ data.tar.gz: 84d9ecc33e21c6921c366d33b3e5be5dcc9d1ac0abbe58783cf09d3be41cc707eff2ac33eeb2d285e21890f96135f2758a2de0cf35cbbef93c2aa5ef871f7e2b
@@ -41,7 +41,7 @@ module Fastlane
41
41
 
42
42
  # Set up commands
43
43
  UI.message("Setting up run commands".yellow)
44
- create_avd_command = [sdkRoot + "/tools/android", "create avd", avd_name, target_id, avd_abi, avd_tag, avd_create_options].join(" ")
44
+ create_avd_command = ["echo \"no\" |", sdkRoot + "/tools/android", "create avd", avd_name, target_id, avd_abi, avd_tag, avd_create_options].join(" ")
45
45
  get_devices_command = sdkRoot + "/tools/android list avd".chomp
46
46
  start_avd_command = [sdkRoot + "/tools/" + emulator_binary, avd_port, "-avd #{params[:avd_name]}", avd_initdata, avd_start_options, "&>#{file.path} &"].join(" ")
47
47
  shell_command = "#{params[:shell_command]}" unless params[:shell_command].nil?
@@ -101,15 +101,23 @@ module Fastlane
101
101
  return port
102
102
  end
103
103
 
104
- def self.waitFor_emulatorBoot(sdkRoot, port)
104
+ def self.waitFor_emulatorBoot(sdkRoot, port, params)
105
105
  UI.message("Waiting for emulator to finish booting.....".yellow)
106
- loop do
107
- stdout, _stdeerr, _status = Open3.capture3(sdkRoot + ["/platform-tools/adb -s emulator-", port].join("") + " shell getprop sys.boot_completed")
106
+ startParams = "#{params[:avd_start_options]}"
108
107
 
109
- if stdout.strip == "1"
110
- break
108
+ if startParams.include? "-no-window"
109
+ Action.sh("wait-for-device")
110
+ Action.sh("adb-devices")
111
+ else
112
+ loop do
113
+ stdout, _stdeerr, _status = Open3.capture3(sdkRoot + ["/platform-tools/adb -s emulator-", port].join("") + " shell getprop sys.boot_completed")
114
+
115
+ if stdout.strip == "1"
116
+ break
117
+ end
111
118
  end
112
119
  end
120
+
113
121
  UI.message("Emulator Booted!".green)
114
122
  end
115
123
 
@@ -1,5 +1,5 @@
1
1
  module Fastlane
2
2
  module AutomatedTestEmulatorRun
3
- VERSION = "0.3"
3
+ VERSION = "0.3.1"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fastlane-plugin-automated_test_emulator_run
3
3
  version: !ruby/object:Gem::Version
4
- version: '0.3'
4
+ version: 0.3.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - Kamil Krzyk