-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
[최종점검] 스터디 과제 제출 #2
Open
sung-silver
wants to merge
19
commits into
develop
Choose a base branch
from
test/#2
base: develop
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Changes from all commits
Commits
Show all changes
19 commits
Select commit
Hold shift + click to select a range
be318b2
[FEAT] 서비스 단에서 도메인 로직 분리
sung-silver 6e2ec20
[STYLE] enum 위치 도메인 아래로 변경
sung-silver ad8387c
[DOMAIN] AgeEnumTest 작성
sung-silver 6154145
[DOMAIN] Result 엔티티에서 getTestDateToString 함수 테스트 작성
sung-silver 86e90bf
[REFACTOR] saveMember 리팩터링, repository에서 명시하지 않아도 되는 메서드 삭제
sung-silver 093d3e8
[FEAT] RestDoc 설정 & 확인
sung-silver a9bc1ca
[REFACOTR] request, response에서 DTO 키워드 제거
sung-silver 02b592d
[FIX] MemberControllerTest initializeController 위치 수정
sung-silver bbde1c6
[FEAT] QuestionControllerTest 작성
sung-silver 36115b4
[FEAT] ResultControllerTest 구현
sung-silver 92b5eea
[FEAT] MemberJpaRepositoryTest 테스트코드 작성
sung-silver f2c0405
[FEAT] ResultJpaRepositoryTest 구현
sung-silver 015bdbc
[ADD] questionJpaRepostiory에 대한 tearDown 추가
sung-silver 4a1e0d3
[FEAT] ResultJpaRepositoryTest 구현
sung-silver 5ef8081
[DEL] 안쓰는 주석 삭제
sung-silver 0d0a196
[MODIFY] AgeEnumTest 각 나이 경계값을 기준으로 테스트 하도록 수정
sung-silver 9285048
[FEAT] MemberServiceTest 구현
sung-silver cea44a2
[FEAT] ResultServiceTest 구현
sung-silver ee9e70f
[FEAT] restdoc .adoc 파일 모두 만들기
sung-silver File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
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
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 |
---|---|---|
@@ -0,0 +1,9 @@ | ||
[[save-member]] | ||
== Save Member | ||
|
||
=== HTTP Request | ||
include::{snippets}/save-member/http-request.adoc[] | ||
|
||
=== HTTP Response | ||
include::{snippets}/save-member/http-response.adoc[] | ||
include::{snippets}/save-member/response-fields.adoc[] |
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 |
---|---|---|
@@ -0,0 +1,9 @@ | ||
[[get-question]] | ||
== GET Question | ||
|
||
=== HTTP Request | ||
include::{snippets}/get-questions/http-request.adoc[] | ||
|
||
=== HTTP Response | ||
include::{snippets}/get-questions/http-response.adoc[] | ||
include::{snippets}/get-questions/response-fields.adoc[] |
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 |
---|---|---|
@@ -0,0 +1,19 @@ | ||
[[save-result]] | ||
== SAVE RESULT | ||
|
||
=== HTTP Request | ||
include::{snippets}/save-result/http-request.adoc[] | ||
|
||
=== HTTP Response | ||
include::{snippets}/save-result/http-response.adoc[] | ||
include::{snippets}/save-result/response-fields.adoc[] | ||
|
||
[[get-all-results]] | ||
== GET ALL RESULTS | ||
|
||
=== HTTP Request | ||
include::{snippets}/get-all-results/http-request.adoc[] | ||
|
||
=== HTTP Response | ||
include::{snippets}/get-all-results/http-response.adoc[] | ||
include::{snippets}/get-all-results/response-fields.adoc[] |
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 |
---|---|---|
@@ -0,0 +1,23 @@ | ||
ifndef::snippets[] | ||
:snippets: "../../build/generated-snippets" | ||
endif::[] | ||
|
||
= HOWOLDAREYOU REST API 문서 | ||
:doctype: book | ||
:icons: font | ||
:source-highlighter: highlightjs | ||
:toc: left | ||
:toclevels: 2 | ||
:seclinks: | ||
|
||
[[Member-API]] | ||
== Member API | ||
include::api/member.adoc[] | ||
|
||
[[Question-API]] | ||
== Question API | ||
include::api/question.adoc[] | ||
|
||
[[Result-API]] | ||
== Result API | ||
include::api/result.adoc[] |
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
9 changes: 9 additions & 0 deletions
9
howoldareu_clone/src/main/java/com/sopt/Server/common/JpaAuditingConfiguration.java
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 |
---|---|---|
@@ -0,0 +1,9 @@ | ||
package com.sopt.Server.common; | ||
|
||
import org.springframework.data.jpa.repository.config.EnableJpaAuditing; | ||
import org.springframework.stereotype.Component; | ||
|
||
@Component | ||
@EnableJpaAuditing | ||
public class JpaAuditingConfiguration { | ||
} |
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
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
6 changes: 6 additions & 0 deletions
6
howoldareu_clone/src/main/java/com/sopt/Server/controller/request/AnswerListRequest.java
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 |
---|---|---|
@@ -0,0 +1,6 @@ | ||
package com.sopt.Server.controller.request; | ||
|
||
import java.util.List; | ||
|
||
public record AnswerListRequest(String nickname, List<AnswerRequest> results) { | ||
} |
6 changes: 0 additions & 6 deletions
6
howoldareu_clone/src/main/java/com/sopt/Server/controller/request/AnswerListRequestDTO.java
This file was deleted.
Oops, something went wrong.
4 changes: 4 additions & 0 deletions
4
howoldareu_clone/src/main/java/com/sopt/Server/controller/request/AnswerRequest.java
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 |
---|---|---|
@@ -0,0 +1,4 @@ | ||
package com.sopt.Server.controller.request; | ||
|
||
public record AnswerRequest(Long questionId, boolean answerType) { | ||
} |
4 changes: 0 additions & 4 deletions
4
howoldareu_clone/src/main/java/com/sopt/Server/controller/request/AnswerRequestDTO.java
This file was deleted.
Oops, something went wrong.
11 changes: 11 additions & 0 deletions
11
howoldareu_clone/src/main/java/com/sopt/Server/controller/response/AllResultsResponse.java
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 |
---|---|---|
@@ -0,0 +1,11 @@ | ||
package com.sopt.Server.controller.response; | ||
|
||
import com.sopt.Server.domain.Result; | ||
|
||
import java.util.List; | ||
|
||
public record AllResultsResponse(Long id, int resultAge, String title, String content, String testedDate, String imgUrl1, String imgUrl2) { | ||
public static AllResultsResponse of(Result result, String title, String content, String testedDate, String imgUrl1, String imgUrl2) { | ||
return new AllResultsResponse(result.getId(), result.getResultAge(), title, content, testedDate, imgUrl1, imgUrl2); | ||
} | ||
} |
9 changes: 0 additions & 9 deletions
9
...ldareu_clone/src/main/java/com/sopt/Server/controller/response/AllResultsResponseDTO.java
This file was deleted.
Oops, something went wrong.
7 changes: 7 additions & 0 deletions
7
howoldareu_clone/src/main/java/com/sopt/Server/controller/response/GetQuestionResponse.java
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 |
---|---|---|
@@ -0,0 +1,7 @@ | ||
package com.sopt.Server.controller.response; | ||
|
||
public record GetQuestionResponse(Long questionId, String questionContent) { | ||
static public GetQuestionResponse of(Long questionId, String questionContent) { | ||
return new GetQuestionResponse(questionId, questionContent); | ||
} | ||
} |
7 changes: 0 additions & 7 deletions
7
...dareu_clone/src/main/java/com/sopt/Server/controller/response/GetQuestionResponseDTO.java
This file was deleted.
Oops, something went wrong.
7 changes: 7 additions & 0 deletions
7
howoldareu_clone/src/main/java/com/sopt/Server/controller/response/ResultResponse.java
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 |
---|---|---|
@@ -0,0 +1,7 @@ | ||
package com.sopt.Server.controller.response; | ||
|
||
public record ResultResponse(String nickname, int resultAge, String title, String content, String imgUrl1, String imgUrl2) { | ||
public static ResultResponse of(String nickname, int resultAge, String title, String content, String imgUrl1, String imgUrl2) { | ||
return new ResultResponse(nickname, resultAge, title, content, imgUrl1, imgUrl2); | ||
} | ||
} |
7 changes: 0 additions & 7 deletions
7
howoldareu_clone/src/main/java/com/sopt/Server/controller/response/ResultResponseDTO.java
This file was deleted.
Oops, something went wrong.
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
10 changes: 10 additions & 0 deletions
10
howoldareu_clone/src/main/java/com/sopt/Server/domain/Question.java
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 |
---|---|---|
@@ -1,13 +1,23 @@ | ||
package com.sopt.Server.domain; | ||
|
||
import jakarta.persistence.*; | ||
import lombok.AccessLevel; | ||
import lombok.Builder; | ||
import lombok.Getter; | ||
import lombok.NoArgsConstructor; | ||
|
||
@Entity | ||
@Getter | ||
@Table(name = "QUESTIONS") | ||
@NoArgsConstructor(access = AccessLevel.PROTECTED) | ||
public class Question { | ||
@Id @GeneratedValue(strategy = GenerationType.IDENTITY) | ||
private Long questionId; | ||
private String questionContent; | ||
|
||
@Builder | ||
public Question(Long questionId, String questionContent) { | ||
this.questionId = questionId; | ||
this.questionContent = questionContent; | ||
} | ||
} |
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
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
파일 분리하는 것 좋네요 ~