Notice
Recent Posts
Recent Comments
Link
일 | 월 | 화 | 수 | 목 | 금 | 토 |
---|---|---|---|---|---|---|
1 | 2 | 3 | 4 | 5 | ||
6 | 7 | 8 | 9 | 10 | 11 | 12 |
13 | 14 | 15 | 16 | 17 | 18 | 19 |
20 | 21 | 22 | 23 | 24 | 25 | 26 |
27 | 28 | 29 | 30 |
Tags
- dependency injection
- HTTP
- JPA
- VUE
- 싱글톤
- 프로토타입
- Setter
- thymeleaf
- vue-cli
- js
- cache
- HTTP 메서드
- Excel
- Kotlin
- Java
- vuex
- Security
- DB
- Spring
- Stateless
- 라이프 사이클
- javascript
- Vue.js
- 캐시
- 로그인
- Singleton
- 의존성 주입
- di
- Repository
- BEAN
Archives
- Today
- Total
목록beforeEach (1)
jhhan의 블로그

저번에 이어서 썼던 Test Code에 대해서 한번 더 다뤄보는 시간을 갖겠습니다. 당연한 것이지만, 코드는 이전 글에서 썼던 코드를 이어서 쓸 것입니다. 이번에는 회원가입을 하는 로직을 만들어보겠습니다. 프로젝트 구조를 보겠습니다. service라는 패키지를 만들었고, MemberService라는 클래스를 만들었습니다. public class MemberService { private final MemberRepository memberRepository = new MemoryMemberRepository(); /** * 회원 가입 */ public Long join(Member member) { /* 중복 회원 안됨 */ Optional result = memberRepository.findByNam..
Spring
2020. 9. 13. 18:36