Closed wmathurin closed 1 month ago
1 Warning | |
---|---|
:warning: | Big PR, try to keep changes smaller if you can. |
Generated by :no_entry_sign: Danger
1 Warning | |
---|---|
:warning: | No Lint Results. |
Generated by :no_entry_sign: Danger
1 Warning | |
---|---|
:warning: | No Lint Results. |
Generated by :no_entry_sign: Danger
1 Warning | |
---|---|
:warning: | No Lint Results. |
Generated by :no_entry_sign: Danger
1 Warning | |
---|---|
:warning: | No Lint Results. |
Generated by :no_entry_sign: Danger
1 Error | |
---|---|
:no_entry_sign: | Tests have failed, see below for more information. |
1 Warning | |
---|---|
:warning: | No Lint Results. |
Name | Classname | Time |
---|---|---|
test[testCleanResyncGhosts] | com.salesforce.androidsdk.reactnative.ReactMobileSyncTest | 132.43 |
Generated by :no_entry_sign: Danger
Attention: Patch coverage is 67.81915%
with 121 lines
in your changes missing coverage. Please review.
Project coverage is 58.98%. Comparing base (
6e20c51
) to head (801ceaa
). Report is 1 commits behind head on dev.
@brandonpage I merged too quickly, I'll address your comments in the next PR
@brandonpage I merged too quickly, I'll address your comments in the next PR
No worries, pretty much everything was NIT or feedback for future releases.
New token end point fields captured
Capturing a few extra fields from token end point (cookie client src, cookie sid client and sid cookie name). Saving them to the user account. We will need them when we change
SalesforceDroidGapActivity
from using front-door to using sessions returned by hybrid login and refresh flows.Simplified data passing auth / user account / account manager
Class diagram highlighting new or modified methods/fields
UserAccount
UserAccountBuilder
Converted to kotlin
New fields (and accompanying setters) mentioned above
New method:
populateFromIdServiceResponse
onPostExecute
ofBaseFinishAuthFlowTask
inOAuthWebviewHelper
at the end of login flowNew method:
populateFromTokenEndpointResponse
onPostExecute
ofBaseFinishAuthFlowTask
inOAuthWebviewHelper
at the end of login flowrefreshStaleToken
ofClientManager
'sAccMgrAuthTokenProvider
(called whenRestClient
gets a 401)getAuthToken
ofAuthenticationService
New method:
populateFromUserAccount
populateFromTokenEndpointResponse
with the response returned by a call to refresh end pointrefreshStaleToken
ofClientManager
'sAccMgrAuthTokenProvider
(called whenRestClient
gets a 401)getAuthToken
ofAuthenticationService
New field/setter
allowUnset
additionAuthValues
causes the new map and old map to be mergedUserAccountManager
New method:
buildAuthBundle
UserAccount
for authenticator serviceNew method:
createAccount
ClientManager
'screateNewAccount
(which is now a one liner)createNewAccount
thanks tobuildAuthBundle
New method:
updateAccount
refreshStaleToken
ofClientManager
'sAccMgrAuthTokenProvider
(called whenRestClient
gets a 401)getAuthToken
ofAuthenticationService
OAuthWebviewHelper
onPostExecute
AccountOptions
inner class -accountOptions
is simply theuserAccount.toBundle()
ClientManager
createNewAccount
- code moved toUserAccountManager
peekRestClient
- callingUserAccountManager
'sbuildUserAccount
to get all the values from account managergetNewAuthToken
- like before it callsrefreshStaleToken
, but that method now returns aUserAccount
instead of a bundle with encrypted valuesrefreshStaleToken
- usesUserAccountBuilder
's new methodspopulateFromUserAccount
,allowUnset
andpopulateFromTokenEndpointResponse
Added / updated tests
UserAccountTest
ClientManagerTest
UserAccountManagerTest
UserAccountManager.createAccount
instead of having to set up aClientManager
and callingcreateNewAccount()