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

[DO NOT REVIEW] Merge PayPal App Switch feature branch #1167

Merged
merged 18 commits into from
Sep 26, 2024

Conversation

richherrera
Copy link
Contributor

Summary of changes

  • These changes were already reviewed as sub-PRs
  • This PR is to trigger CI checks

Checklist

  • Added a changelog entry
  • Relevant test coverage

Authors

@richherrera @saperi22 @tdchow @jaxdesmarais @sshropshire @scannillo

richherrera and others added 16 commits July 24, 2024 11:27
* Add  feature vault request keys

* Update fragment to have the same URI as iOS

* Add enablePayPalAppSwitch parameter

* Add UT

* Address PR comments

* Change primitive type
* Add Checkbox app switch to Demo App

* Update Factory request with settings app switch value

* Update Demo/src/main/res/xml/settings.xml

Co-authored-by: Sarah Koop <[email protected]>

---------

Co-authored-by: Sarah Koop <[email protected]>
* Pass app linkk return uri as paremeter

* Update json parameters with uri

* Update UTs

* Catch Uri null

* Address PR comment

* Rename parameter

* Update validation to append new parameters
* Pass app linkk return uri as paremeter

* Update json parameters with uri

* Update UTs

* Catch Uri null

* Address PR comment

* Rename parameter

* Update validation to append new parameters

* Map payPalApprovalURL key from response

* Add and fix UTs

* Add method to verified if paypal is installed

* Check linkType to parse response model

* Add UTs and textures

* Add method to append query items and create app switch uri

* Fix tests and modify baToken validation

* Add linkType enum

* Update LinkType on venmo client

* Update PayPal/src/main/java/com/braintreepayments/api/paypal/PayPalInternalClient.java

Change BraintreeException instead of Exception on internal client

Co-authored-by: sshropshire <[email protected]>

* Add missing import

* Change isPayPalInstalled method to property

* Linting

* Revert changes on isPayPalInstalled

* Lint LinkTye

* Revert linkTyope validation to instantiate PaymentResource

* Use linkType enum instead of String

* Fix UTs

* Add RestrictTo on LinkType enum

---------

Co-authored-by: sshropshire <[email protected]>
* Remove publishing javadocs from maven publish (#1082)

* Remove appLinkEnabled property (#1085)

* Remove appLinkEnabled property from PayPalRequest - app link is now required for PayPal

* Remove unused import

* Add breaking changes section to changelog

* Update 3DS and GraphQL Endpoint Sent to FPTI (v5) (#1080)

* update endpoint logic for 3DS and graphQL
* update constants
* add CHANGELOG entry
* simplify cleanedPath logic for 3DS
* remove analytics path check since that post request uses a different http client

* Parcelize Nonce Classes (#1087)

* Convert Nonce classes to Kotlin and implement Parcelable using the Parcelize annotation

* Restrict constructor scopes

* Convert nonce classes to data classes and remove detekt rule

* Remove unused type property in LocalPaymentNonce

* Paypal Module Kotlin Conversion (#1088)

* Convert PayPalPaymentResource to Kotlin

* Convert PayPalPaymentAuthResultInfo to Kotlin

* Convert PayPalBrowserSwitchException to Kotlin

* Convert PayPal internal callbacks to Kotlin

* Convert PayPalPaymentAuthRequestParams to Kotlin

* Convert PayPalCreditFinancingAmount to Kotlin

* Convert PayPalCreditFinancing to Kotlin

* Convert PayPalPaymentIntent to Kotlin

* Delete Java PayPalPaymentIntent file

* Add PayPalPaymentIntent to changelog

* Rename payerAcceptance to hasPayerAcceptance

* Convert PayPal Classes to Kotlin (#1089)

* Convert PayPalPaymentResource to Kotlin

* Convert PayPalPaymentAuthResultInfo to Kotlin

* Convert PayPalBrowserSwitchException to Kotlin

* Convert PayPal internal callbacks to Kotlin

* Convert PayPalPaymentAuthRequestParams to Kotlin

* Convert PayPalCreditFinancingAmount to Kotlin

* Convert PayPalCreditFinancing to Kotlin

* Convert PayPalPaymentIntent to Kotlin

* Delete Java PayPalPaymentIntent file

* Convert PayPalAccount to Kotlin

* Convert PayPalRequest, PayPalVaultRequest, and PayPalCheckoutRequest to Kotlin

* Update changelog wording

* Changelog updates

* Move enums to separate files

* Convert PayPal module classes to Kotlin (#1091)

* Convert PayPalLineItem to Kotlin

* Delete PayPalAccount.java

* Convert PayPalClient to Kotlin

* Convert PayPalInternalClient to Kotlin

* Rename PayPalLineItemKind enums

* Update unitAmount to non null

* Remove old analytic events lingering from v4 (#1093)

* Drop android prefix from each analytics event name (#1095)

* Merge branch 'main' into update-paypal-classes

* Update PayPal classes with Java App Switch logic

* Override VaultRequest parameter if venice app is installed or not

* Fix lint issues

* Remove unnecessary access modifier

* Fix lint issue

---------

Co-authored-by: Tim Chow <[email protected]>
Co-authored-by: Jax DesMarais-Leder <[email protected]>
Co-authored-by: scannillo <[email protected]>
* Add Toast to notify email cannot be nil for this feature

* Update Demo/src/main/java/com/braintreepayments/demo/PayPalFragment.java

Co-authored-by: Tim Chow <[email protected]>

---------

Co-authored-by: Tim Chow <[email protected]>
* Add toast with pairingId

* Update Demo/src/main/java/com/braintreepayments/demo/PayPalFragment.java

Co-authored-by: Tim Chow <[email protected]>

---------

Co-authored-by: Tim Chow <[email protected]>
* Add paypal_installed param

* Update UTs

* Fix pairing id toast message

* Move paypal_installed tag to batch params

* Add device instector on Braintree Client

* Fix UTS

* Fix lint

* Remove Device Inspector reference from BraintreeClient

* Make public Device Inspector to be used by PayPalInternalClient

* Inject Device Inspector on PayPalInternalClient

* Fix UTs

* Move supress
* Github Action workflow for Firebase deploy
* Convert version sdk to string

* Fix ut

* Change SDK int to release version

* Fix validation: We need to check if the feature is enabled in settings to avoid overwriting the variable.

* Revert version Release to SDK int and cast it to string
* Add app switch event names

* Add linkType property

* Change methods access level to be used by PayPalClient

* Use PayPalInternalClients to validate link type

* Add APP_SWTCH_STARTED event

* Add success and failure events for app switch flow

* Fix commented code

* Change demo paypal webview fragment input type

* Add additional conversion event

* Move lnkType setup and add handleReturnStarted event

* Fix lint

* Fix lint

* Remove unnecessary event failure call

* Move handle return event

* Add some tests

* Add tests

* Address PR feedback

* Rename LinkType cases

* Add canceled event

* Change failed to canceled, fix tests

* Update PayPal/src/main/java/com/braintreepayments/api/paypal/PayPalClient.kt

Co-authored-by: Jax DesMarais-Leder <[email protected]>

---------

Co-authored-by: Jax DesMarais-Leder <[email protected]>
@richherrera richherrera requested a review from a team as a code owner September 25, 2024 21:09
@richherrera richherrera marked this pull request as draft September 25, 2024 21:10
@richherrera richherrera marked this pull request as ready for review September 26, 2024 15:32
@richherrera richherrera merged commit 9d8508f into main Sep 26, 2024
4 checks passed
@richherrera richherrera deleted the paypal-app-switch-feature branch September 26, 2024 21:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants