File tree Expand file tree Collapse file tree 2 files changed +17
-2
lines changed
main/java/com/google/firebase/auth Expand file tree Collapse file tree 2 files changed +17
-2
lines changed Original file line number Diff line number Diff line change @@ -425,11 +425,11 @@ class FirebaseAuth constructor(
425
425
setResult = { responseBody ->
426
426
FirebaseUserImpl (app, jsonParser.parseToJsonElement(responseBody).jsonObject)
427
427
},
428
- ).task.continueWith {
428
+ ).task.addOnSuccessListener {
429
429
updateByGetAccountInfo()
430
430
>>>>>>> 25efe1c (ktlint formatting + update of user data after signInWithCustomToken + photoUrl and displayName implementation)
431
431
}
432
- return source.result
432
+ return source
433
433
}
434
434
435
435
internal fun updateByGetAccountInfo (): Task <AuthResult > {
Original file line number Diff line number Diff line change @@ -53,6 +53,21 @@ class AuthTest : FirebaseTest() {
53
53
assertEquals(false , auth.currentUser?.isAnonymous)
54
54
}
55
55
56
+ /* @Test
57
+ fun `should authenticate via custom token`() =
58
+ runTest {
59
+ val user = auth.createUserWithEmailAndPassword(email, "test123").await()
60
+ auth
61
+ .signInWithCustomToken(
62
+ user.user
63
+ .getIdToken(false)
64
+ .await()
65
+ .token ?: "",
66
+ ).await()
67
+
68
+ assertEquals(false, auth.currentUser?.isAnonymous)
69
+ }*/
70
+
56
71
@Test
57
72
fun `should update displayName and photoUrl` () =
58
73
runTest {
You can’t perform that action at this time.
0 commit comments