-
Notifications
You must be signed in to change notification settings - Fork 38
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
13 changed files
with
218 additions
and
77 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,71 @@ | ||
Feature: Generating Android app bundles | ||
|
||
Scenario: Single-module default app bundles successfully | ||
When I bundle "default_app" using the "standard" bugsnag config | ||
Then I should receive 2 requests | ||
|
||
And the request 0 is valid for the Build API | ||
And the payload field "appVersion" equals "1.0" for request 0 | ||
And the payload field "apiKey" equals "TEST_API_KEY" for request 0 | ||
And the payload field "builderName" is not null for request 0 | ||
And the payload field "buildTool" equals "gradle-android" for request 0 | ||
And the payload field "appVersionCode" equals "1" for request 0 | ||
And the payload field "sourceControl.provider" equals "github" for request 0 | ||
And the payload field "sourceControl.repository" equals "https://github.com/bugsnag/bugsnag-android-gradle-plugin.git" for request 0 | ||
And the payload field "sourceControl.revision" is not null for request 0 | ||
|
||
And the payload field "metadata.os_arch" is not null for request 0 | ||
And the payload field "metadata.os_name" is not null for request 0 | ||
And the payload field "metadata.os_version" is not null for request 0 | ||
And the payload field "metadata.java_version" is not null for request 0 | ||
And the payload field "metadata.gradle_version" is not null for request 0 | ||
And the payload field "metadata.git_version" is not null for request 0 | ||
|
||
And the request 1 is valid for the Android Mapping API | ||
And the field "apiKey" for multipart request 1 equals "TEST_API_KEY" | ||
And the field "versionCode" for multipart request 1 equals "1" | ||
And the field "versionName" for multipart request 1 equals "1.0" | ||
And the field "appId" for multipart request 1 equals "com.bugsnag.android.example" | ||
And the field "overwrite" for multipart request 1 is null | ||
|
||
Scenario: Bundling multiple flavors automatically | ||
When I bundle "flavors" using the "standard" bugsnag config | ||
Then I should receive 4 requests | ||
|
||
And the request 0 is valid for the Build API | ||
And the payload field "appVersion" equals "1.0" for request 0 | ||
And the payload field "apiKey" equals "TEST_API_KEY" for request 0 | ||
And the payload field "appVersionCode" equals "1" for request 0 | ||
|
||
And the request 1 is valid for the Build API | ||
And the payload field "appVersion" equals "1.0" for request 1 | ||
And the payload field "apiKey" equals "TEST_API_KEY" for request 1 | ||
And the payload field "appVersionCode" equals "1" for request 1 | ||
|
||
And the request 2 is valid for the Android Mapping API | ||
And the field "apiKey" for multipart request 2 equals "TEST_API_KEY" | ||
And the field "versionCode" for multipart request 2 equals "1" | ||
And the field "versionName" for multipart request 2 equals "1.0" | ||
And the field "appId" for multipart request 2 equals "com.bugsnag.android.example.bar" | ||
|
||
And the request 3 is valid for the Android Mapping API | ||
And the field "apiKey" for multipart request 3 equals "TEST_API_KEY" | ||
And the field "versionCode" for multipart request 3 equals "1" | ||
And the field "versionName" for multipart request 3 equals "1.0" | ||
And the field "appId" for multipart request 3 equals "com.bugsnag.android.example.foo" | ||
|
||
Scenario: Bundling single flavor | ||
When I bundle the "Foo" variantOutput for "flavors" using the "standard" bugsnag config | ||
Then I should receive 2 requests | ||
|
||
And the request 0 is valid for the Build API | ||
|
||
And the request 1 is valid for the Android Mapping API | ||
And the field "apiKey" for multipart request 1 equals "TEST_API_KEY" | ||
And the field "versionCode" for multipart request 1 equals "1" | ||
And the field "versionName" for multipart request 1 equals "1.0" | ||
And the field "appId" for multipart request 1 equals "com.bugsnag.android.example.foo" | ||
|
||
Scenario: Auto upload disabled | ||
When I bundle "default_app" using the "all_disabled" bugsnag config | ||
Then I should receive no requests |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Binary file not shown.
3 changes: 1 addition & 2 deletions
3
features/fixtures/app/gradle/wrapper/gradle-wrapper.properties
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,6 +1,5 @@ | ||
#Wed Mar 14 16:38:05 GMT 2018 | ||
distributionBase=GRADLE_USER_HOME | ||
distributionPath=wrapper/dists | ||
distributionUrl=https\://services.gradle.org/distributions/gradle-4.6-bin.zip | ||
zipStoreBase=GRADLE_USER_HOME | ||
zipStorePath=wrapper/dists | ||
distributionUrl=https\://services.gradle.org/distributions/gradle-4.1-all.zip |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,4 @@ | ||
#!/usr/bin/env bash | ||
|
||
cd features/fixtures/app | ||
./gradlew :module:clean :module:bundleFoo --stacktrace |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,14 @@ | ||
#!/usr/bin/env bash | ||
|
||
# Alter git remote origin url in case protocol differs | ||
PREV_REMOTE=`git config --get remote.origin.url` | ||
git config --replace-all remote.origin.url "https://github.com/bugsnag/bugsnag-android-gradle-plugin.git" | ||
|
||
function resetGitConfig { | ||
git config --replace-all remote.origin.url $PREV_REMOTE | ||
} | ||
|
||
trap resetGitConfig EXIT | ||
|
||
cd features/fixtures/app | ||
./gradlew :module:clean :module:bundle --stacktrace |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,5 @@ | ||
group = com.bugsnag | ||
version = 3.5.0 | ||
version = 3.6.0 | ||
|
||
ANDROID_MIN_SDK_VERSION=14 | ||
ANDROID_TARGET_SDK_VERSION=27 | ||
|
Oops, something went wrong.