-
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.
- Loading branch information
1 parent
5ca0594
commit 9a84c24
Showing
1 changed file
with
24 additions
and
24 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 |
---|---|---|
|
@@ -15,30 +15,30 @@ | |
@SpringBootTest | ||
class UserServiceTest { | ||
|
||
@Autowired | ||
UserService userService; | ||
|
||
@Autowired | ||
UserDao userDao; | ||
|
||
@Transactional | ||
@Rollback(value = false) | ||
@Test | ||
@DisplayName("유저_회원가입_테스트") | ||
void 유저_회원가입_테스트() throws Exception { | ||
//given | ||
String email = "[email protected]"; | ||
String password = "123456abC!"; | ||
String name = "노성준"; | ||
PostUserSignupRequest postUserRequest = new PostUserSignupRequest(email, password, name); | ||
|
||
//when | ||
PostUserSignupResponse postUserResponse = userService.signup(postUserRequest); | ||
User findUser = userDao.findUserByEmail(email); | ||
|
||
//then | ||
Assertions.assertThat(postUserResponse.getUserId()).isEqualTo(findUser.getUserId()); | ||
} | ||
// @Autowired | ||
// UserService userService; | ||
// | ||
// @Autowired | ||
// UserDao userDao; | ||
// | ||
// @Transactional | ||
// @Rollback(value = false) | ||
// @Test | ||
// @DisplayName("유저_회원가입_테스트") | ||
// void 유저_회원가입_테스트() throws Exception { | ||
// //given | ||
// String email = "[email protected]"; | ||
// String password = "123456abC!"; | ||
// String name = "노성준"; | ||
// PostUserSignupRequest postUserRequest = new PostUserSignupRequest(email, password, name); | ||
// | ||
// //when | ||
// PostUserSignupResponse postUserResponse = userService.signup(postUserRequest); | ||
// User findUser = userDao.findUserByEmail(email); | ||
// | ||
// //then | ||
// Assertions.assertThat(postUserResponse.getUserId()).isEqualTo(findUser.getUserId()); | ||
// } | ||
|
||
// @Transactional | ||
// @Test | ||
|