-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[Server] 클라이언트와 api 연동 작업 (login, socket history) (#209)
* feat: socket 빈 히스토리면 [] 보내기 * feat: 로그인시 유저 닉네임도 같이 보내주기
- Loading branch information
1 parent
5c2f20a
commit 462fe15
Showing
3 changed files
with
14 additions
and
6 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
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -199,13 +199,18 @@ describe('AuthService', () => { | |
email: '[email protected]', | ||
provider: ProviderType.APPLE, | ||
}; | ||
const existUser = { email: user.email, userId: 1 } as UserModel; | ||
const existUser = { | ||
email: user.email, | ||
userId: 1, | ||
nickname: 'test', | ||
} as UserModel; | ||
jest | ||
.spyOn(authService, 'authenticateWithEmailAndProvider') | ||
.mockResolvedValue(existUser); | ||
jest.spyOn(authService, 'loginUser').mockReturnValue({ | ||
accessToken: 'access_token', | ||
refreshToken: 'refresh_token', | ||
nickname: 'test', | ||
}); | ||
|
||
const result = await authService.loginWithEmailAndProvider(user); | ||
|
@@ -252,6 +257,7 @@ describe('AuthService', () => { | |
jest.spyOn(authService, 'loginUser').mockReturnValue({ | ||
accessToken: 'access_token', | ||
refreshToken: 'refresh_token', | ||
nickname: 'NewUser', | ||
}); | ||
|
||
const result = await authService.registerUser(user); | ||
|
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