fastlane-plugin-browserstack 0.3.1 → 0.3.3

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
  SHA256:
3
- metadata.gz: 0285ca4594a863c425e781f25bfbf4b438d205cd11610f54aae33a5fe0c81542
4
- data.tar.gz: 2d0f0637ad9baa0364deded8cb3422f243f7440c52138dd236713042892a3315
3
+ metadata.gz: 02b08722f9335fc078a5617af4cf858c6a4d39c3288f39b1bbdc16174c5eb23e
4
+ data.tar.gz: e823a0737ab4dc521214aba96cfbb1b1fde441b76337ba913222f8deb19c0f31
5
5
  SHA512:
6
- metadata.gz: 25d647f2033714ac168ec1d304244ac36d2c9b2e753852cc3032703d4749e441525c07540d9b58fb113e559794ceb6264b6ef7149aa5f5c917787d70de61054f
7
- data.tar.gz: 0f2c887e47055200e0ad48717e7b3d2e61e66018494652afddeda70588e06237646e202c64113c9f0fed847c6e5bad326c8d5d9c7e0e3c8b83aad65dad695e7e
6
+ metadata.gz: a392e780b3fef996572051cf746072fd4763e422142671ac4b5cad330c161c08625ed16cdc7b790a26fa25f1f164ba81030ca86db96b498a263027a395bf1183
7
+ data.tar.gz: d106335e6ba0c5377b4087cf3fe02d1726bba575b60f9d67da229291407024d7456a6af08470bfaef3125cafc96301435e77fb461777c1f049c90cc9e4d330f9
data/README.md CHANGED
@@ -12,7 +12,7 @@ fastlane add_plugin browserstack
12
12
 
13
13
  ## About
14
14
 
15
- Uploads IPA and APK files to BrowserStack for automation and manual testing.
15
+ Uploads IPA, APK and AAB files to BrowserStack for automation and manual testing.
16
16
 
17
17
  ## Documentation
18
18
 
@@ -21,9 +21,38 @@ Refer [App Automate](https://www.browserstack.com/app-automate/appium/fastlane)
21
21
 
22
22
  ## Example
23
23
 
24
- Check out the [example `Fastfile`](fastlane/Fastfile) to see how to use this plugin. Try it by including that in your project's Fastfile, running `fastlane install_plugins` and `bundle exec fastlane test`.
25
-
26
24
  Please refer this [sample android project](https://github.com/browserstack/browserstack-android-sample-app), which demonstrates the use of this plugin.
25
+ You can easily upload your app using [BrowserStack fastlane Plugin](https://rubygems.org/gems/fastlane-plugin-browserstack) and execute your test on BrowserStack cloud. In order to configure the plugin add below action in your Fastfile. You can also check our [repository](https://github.com/browserstack/browserstack-fastlane-plugin).
26
+ ```
27
+ upload_to_browserstack_app_automate(
28
+ browserstack_username: ENV["BROWSERSTACK_USERNAME"],
29
+ browserstack_access_key: ENV["BROWSERSTACK_ACCESS_KEY"],
30
+ file_path: "<path_to_your_apk_ipa_or_aab_file>",
31
+ custom_id: "<custom_id_name>"
32
+ )
33
+ ```
34
+ ```
35
+ Note: custom_id is optional. You can upload multiple builds under the same custom_id.
36
+ Use custom_id in 'app' capability for Appium to always pick the last uploaded build.
37
+ The file_path parameter is not required if the app was built in the same lane with the help of Gradle or Gym plugin.
38
+ ```
39
+
40
+ For uploading your app to AppLive use the following action in the fastfile
41
+ ```
42
+ upload_to_browserstack_app_live(
43
+ browserstack_username: ENV["BROWSERSTACK_USERNAME"],
44
+ browserstack_access_key: ENV["BROWSERSTACK_ACCESS_KEY"],
45
+ file_path: "<path_to_your_apk_ipa_or_aab_file>"
46
+ )
47
+ ```
48
+ Check out the example [Fastfile](https://github.com/browserstack/browserstack-fastlane-plugin/blob/master/fastlane/Fastfile) to see how to use this plugin. Try it by including that in your project's Fastfile, running `fastlane install_plugins` and `bundle exec fastlane test`. Please refer to this [sample android project](https://github.com/browserstack/browserstack-android-sample-app), which demonstrates the use of this plugin.
49
+
50
+ Once the app upload is successful, the app id of the app will be stored in an environment variable, "BROWSERSTACK_APP_ID" and it can be accessed in your tests in the following way :
51
+ ```
52
+ String app = System.getenv("BROWSERSTACK_APP_ID"); // Get app id from environment variable.
53
+ capabilities.setCapability("app", app); // Add app id to driver capability.
54
+ ```
55
+
27
56
 
28
57
  ## Run tests for this plugin
29
58
 
@@ -44,7 +73,7 @@ For any other issues and feedback about this plugin, please submit it to this re
44
73
 
45
74
  ## Troubleshooting
46
75
 
47
- If you have trouble using plugins, check out the [Plugins Troubleshooting](https://docs.fastlane.tools/plugins/plugins-troubleshooting/) guide.
76
+ If you have trouble using plugins, check out the [Plugins Troubleshooting guide](https://docs.fastlane.tools/plugins/plugins-troubleshooting/).
48
77
 
49
78
  ## Using _fastlane_ Plugins
50
79
 
@@ -8,7 +8,7 @@ module Fastlane
8
8
  BROWSERSTACK_APP_ID ||= :BROWSERSTACK_APP_ID
9
9
  end
10
10
  class UploadToBrowserstackAppAutomateAction < Action
11
- SUPPORTED_FILE_EXTENSIONS = ["apk", "ipa"]
11
+ SUPPORTED_FILE_EXTENSIONS = ["apk", "ipa", "aab"]
12
12
  UPLOAD_API_ENDPOINT = "https://api-cloud.browserstack.com/app-automate/upload"
13
13
 
14
14
  def self.run(params)
@@ -69,8 +69,15 @@ module Fastlane
69
69
  # Shared value for ipa path if it was generated by gym https://docs.fastlane.tools/actions/gym/.
70
70
  return Actions.lane_context[Actions::SharedValues::IPA_OUTPUT_PATH]
71
71
  else
72
- # Shared value for apk if it was generated by gradle.
73
- return Actions.lane_context[Actions::SharedValues::GRADLE_APK_OUTPUT_PATH]
72
+ # Shared value for apk/aab if it was generated by gradle.
73
+ apk_path = Actions.lane_context[Actions::SharedValues::GRADLE_APK_OUTPUT_PATH]
74
+ aab_path = Actions.lane_context[Actions::SharedValues::GRADLE_AAB_OUTPUT_PATH]
75
+
76
+ if !apk_path.nil?
77
+ return apk_path
78
+ else
79
+ return aab_path
80
+ end
74
81
  end
75
82
  end
76
83
 
@@ -8,7 +8,7 @@ module Fastlane
8
8
  BROWSERSTACK_LIVE_APP_ID ||= :BROWSERSTACK_LIVE_APP_ID
9
9
  end
10
10
  class UploadToBrowserstackAppLiveAction < Action
11
- SUPPORTED_FILE_EXTENSIONS = ["apk", "ipa"]
11
+ SUPPORTED_FILE_EXTENSIONS = ["apk", "ipa", "aab"]
12
12
  UPLOAD_API_ENDPOINT = "https://api-cloud.browserstack.com/app-live/upload"
13
13
 
14
14
  def self.run(params)
@@ -68,8 +68,15 @@ module Fastlane
68
68
  # Shared value for ipa path if it was generated by gym https://docs.fastlane.tools/actions/gym/.
69
69
  return Actions.lane_context[Actions::SharedValues::IPA_OUTPUT_PATH]
70
70
  else
71
- # Shared value for apk if it was generated by gradle.
72
- return Actions.lane_context[Actions::SharedValues::GRADLE_APK_OUTPUT_PATH]
71
+ # Shared value for apk/aab if it was generated by gradle.
72
+ apk_path = Actions.lane_context[Actions::SharedValues::GRADLE_APK_OUTPUT_PATH]
73
+ aab_path = Actions.lane_context[Actions::SharedValues::GRADLE_AAB_OUTPUT_PATH]
74
+
75
+ if !apk_path.nil?
76
+ return apk_path
77
+ else
78
+ return aab_path
79
+ end
73
80
  end
74
81
  end
75
82
 
@@ -1,5 +1,5 @@
1
1
  module Fastlane
2
2
  module Browserstack
3
- VERSION = "0.3.1"
3
+ VERSION = "0.3.3"
4
4
  end
5
5
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fastlane-plugin-browserstack
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.1
4
+ version: 0.3.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - BrowserStack
8
- autorequire:
8
+ autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-01-24 00:00:00.000000000 Z
11
+ date: 2024-07-22 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rest-client
@@ -156,7 +156,7 @@ dependencies:
156
156
  - - ">="
157
157
  - !ruby/object:Gem::Version
158
158
  version: 2.96.1
159
- description:
159
+ description:
160
160
  email: support@browserstack.com
161
161
  executables: []
162
162
  extensions: []
@@ -173,7 +173,7 @@ homepage: https://github.com/browserstack/browserstack-fastlane-plugin
173
173
  licenses:
174
174
  - MIT
175
175
  metadata: {}
176
- post_install_message:
176
+ post_install_message:
177
177
  rdoc_options: []
178
178
  require_paths:
179
179
  - lib
@@ -188,9 +188,8 @@ required_rubygems_version: !ruby/object:Gem::Requirement
188
188
  - !ruby/object:Gem::Version
189
189
  version: '0'
190
190
  requirements: []
191
- rubyforge_project:
192
- rubygems_version: 2.7.6
193
- signing_key:
191
+ rubygems_version: 3.4.10
192
+ signing_key:
194
193
  specification_version: 4
195
194
  summary: Uploads IPA and APK files to BrowserStack for automation and manual testing.
196
195
  test_files: []