Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Update Braintree Core to 4.49.1 #479

Merged
merged 4 commits into from
Jul 29, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

## unreleased

* Bump braintree_android module dependency versions to `4.48.0`
* Bump braintree_android module dependency versions to `4.49.1`

## 6.16.0

Expand Down
8 changes: 4 additions & 4 deletions Drop-In/build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -65,8 +65,8 @@ android {
dependencies {
// TODO: consider making this api in core to allow for PaymentType and other @IntDef / @StringDef constants to work for merchants
implementation 'androidx.annotation:annotation:1.1.0'
implementation 'androidx.fragment:fragment:1.4.1'
implementation 'androidx.lifecycle:lifecycle-runtime-ktx:2.4.1'
implementation 'androidx.fragment:fragment:1.7.1'
implementation 'androidx.lifecycle:lifecycle-runtime:2.7.0'

api deps.braintreeCore
api deps.threeDSecure
Expand Down Expand Up @@ -102,8 +102,8 @@ dependencies {
androidTestImplementation 'androidx.test:rules:1.4.0'
androidTestImplementation 'androidx.test:runner:1.4.0'
androidTestImplementation 'androidx.test.ext:junit:1.1.3'
androidTestImplementation 'androidx.fragment:fragment-testing:1.3.5'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.3.0'
androidTestImplementation 'androidx.fragment:fragment-testing:1.7.1'
androidTestImplementation 'androidx.test.espresso:espresso-core:3.6.1'
androidTestImplementation 'org.mockito:mockito-core:5.2.0'
}

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -152,7 +152,7 @@ public void onAuthorizationResult(@Nullable Authorization authorization, @Nullab
callback.onResult(null, graphQLError);
}

braintreeClient.sendGraphQLPOST(base.toString(), (responseBody, httpError) -> {
braintreeClient.sendGraphQLPOST(base, (responseBody, httpError) -> {
if (responseBody != null) {
callback.onResult(paymentMethodNonce, null);
braintreeClient.sendAnalyticsEvent("delete-payment-methods.succeeded");
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ public BraintreeClient build() {
callback.onResult(null, sendGraphQLPOSTError);
}
return null;
}).when(braintreeClient).sendGraphQLPOST(anyString(), any(HttpResponseCallback.class));
}).when(braintreeClient).sendGraphQLPOST(any(), any(HttpResponseCallback.class));

return braintreeClient;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -291,7 +291,7 @@ public void deletePaymentMethodNonce_withTokenizationKey_throwsAnError() {
assertEquals("A client token with a customer id must be used to delete a payment method nonce.",
captor.getValue().getMessage());

verify(braintreeClient, never()).sendGraphQLPOST(anyString(), any(HttpResponseCallback.class));
verify(braintreeClient, never()).sendGraphQLPOST(any(), any(HttpResponseCallback.class));
}

@Test
Expand Down Expand Up @@ -374,10 +374,10 @@ public void deletePaymentMethodNonce_postToGraphQL()

verify(braintreeClient).getIntegrationType();

ArgumentCaptor<String> captor = ArgumentCaptor.forClass(String.class);
ArgumentCaptor<JSONObject> captor = ArgumentCaptor.forClass(JSONObject.class);
verify(braintreeClient).sendGraphQLPOST(captor.capture(), any(HttpResponseCallback.class));

JSONObject graphQlRequest = new JSONObject(captor.getValue());
JSONObject graphQlRequest = captor.getValue();

String expectedGraphQLQuery = GraphQLQueryHelper.getQuery(
ApplicationProvider.getApplicationContext(), R.raw.delete_payment_method_mutation);
Expand Down
2 changes: 1 addition & 1 deletion build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ buildscript {
}
}

ext.brainTreeVersion = "4.48.0"
ext.brainTreeVersion = "4.49.1"
jaxdesmarais marked this conversation as resolved.
Show resolved Hide resolved

ext.deps = [
"braintreeCore" : "com.braintreepayments.api:braintree-core:$brainTreeVersion",
Expand Down
Loading