Skip to content
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

[team-01][BE] API - 전체 Todo 조회 요청 / 전체 History 조회 요청 #127

Merged
merged 22 commits into from Apr 12, 2022

Commits on Apr 11, 2022

  1. fix: PR 리뷰 반영

    - createdTime, updatedTime 네이밍 수정
    - userId -> user 로 수정
    - 생성자가 하나인 클래스 @Autowired 명시하지 않도록 수정
    - 테스트 코드 중 여러 개의 assertThat() 을 사용하는 테스트에서 assertAll() 을 사용하도록 수정
    - @ParameterizedTest 를 이용해 테스트할 valuesource 를 중복 작성하지 않게하고, 테스트의 예상 값이 변경되어도 actual 값을 따로 변경해주지 않도록 수정
    - 테스트 할 때 sql 파일이 초기화되도록 @Sql 사용
    donggi-lee-bit committed Apr 11, 2022
    Configuration menu
    Copy the full SHA
    53fa7d7 View commit details
    Browse the repository at this point in the history
  2. feat: 전체 todo 를 조회하는 기능 구현

    - GET api/todos path 로 요청이 오면 전체 todo 를 전달하도록 controller 구현
    - service 계층에서 해당 요청을 repository 계층에 요청하도록 구현
    - repository 게층에서 연결된 db 에서 sql 문을 통해 데이터를 가져와 List 에 담아서 데이터를 반환하도록 구현
    
    Closes: #20
    donggi-lee-bit committed Apr 11, 2022
    Configuration menu
    Copy the full SHA
    b95c219 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    458eaeb View commit details
    Browse the repository at this point in the history
  4. feat: 전체 Histories를 조회하는 기능 구현

    - GET /api/histories
    ku-kim committed Apr 11, 2022
    Configuration menu
    Copy the full SHA
    25e1a6a View commit details
    Browse the repository at this point in the history
  5. Configuration menu
    Copy the full SHA
    ed6fbcd View commit details
    Browse the repository at this point in the history

Commits on Apr 12, 2022

  1. Configuration menu
    Copy the full SHA
    5c942f4 View commit details
    Browse the repository at this point in the history
  2. refactor: Service 계층에서 Optional 처리하도록 변경

    - 전체 Todo 요청 시 데이터가 없으면 NoSuchElementException 을 반환
    donggi-lee-bit committed Apr 12, 2022
    Configuration menu
    Copy the full SHA
    bac1fe7 View commit details
    Browse the repository at this point in the history
  3. Configuration menu
    Copy the full SHA
    bcc4df4 View commit details
    Browse the repository at this point in the history
  4. refactor: 테스트 코드 리팩토링

    - assertThat() 의 contains() 와 hasSize() 를 이용해 테스트 코드의 중복 코드 제거
    donggi-lee-bit committed Apr 12, 2022
    Configuration menu
    Copy the full SHA
    38884fa View commit details
    Browse the repository at this point in the history
  5. Merge pull request #37 from ku-kim/feature/BE/GET_api_todos_list

    [BE] API Server - 전체 Todo 조회 요청 기능 구현
    ku-kim committed Apr 12, 2022
    Configuration menu
    Copy the full SHA
    ca6114e View commit details
    Browse the repository at this point in the history
  6. Merge pull request #40 from ku-kim/feature/BE/GET_api_histories

    [BE] API Server - 전체 History를 조회하도록 기능 구현
    donggi-lee-bit committed Apr 12, 2022
    Configuration menu
    Copy the full SHA
    b720734 View commit details
    Browse the repository at this point in the history
  7. Configuration menu
    Copy the full SHA
    be0f505 View commit details
    Browse the repository at this point in the history
  8. refactor: Todo, History 컨트롤러의 불필요한 autowired 제거, @RequestMapping("api…

    …") -> "/api" 변경
    
    - TodoController의 TodoService final 추가
    ku-kim committed Apr 12, 2022
    Configuration menu
    Copy the full SHA
    444ebd7 View commit details
    Browse the repository at this point in the history
  9. Configuration menu
    Copy the full SHA
    ae4b909 View commit details
    Browse the repository at this point in the history
  10. Configuration menu
    Copy the full SHA
    a76acac View commit details
    Browse the repository at this point in the history
  11. feat: test 환경의 별도의 application.yml .sql 생성

    - 기존 main, test 분리되지 않은 문제가 있었음
    - test 폴더 밑의 resources를 만들어 독립적인 환경으로 관리
    ku-kim committed Apr 12, 2022
    Configuration menu
    Copy the full SHA
    46d734f View commit details
    Browse the repository at this point in the history
  12. refactor: findAll() 메서드 반환 타입 Optional 제거

    - finAll() 메서드로 history 와 todo 의 데이터를 찾을 때 아무것도 없다면 NoSuchElementException 을 던져주도록 변경
    donggi-lee-bit committed Apr 12, 2022
    Configuration menu
    Copy the full SHA
    972c709 View commit details
    Browse the repository at this point in the history
  13. refactor: 컨트롤러의 @RequestMapping("/api")들을 WebConfig 에서 관리하도록 수정

    - WebMvcConfigurer.configurePathMatch 사용하여 "/api" Prefix를 codesquad.be.todoserver.controller 패키지 이하 컨트롤러에 매핑하도록 사용
    ku-kim committed Apr 12, 2022
    Configuration menu
    Copy the full SHA
    7f29871 View commit details
    Browse the repository at this point in the history
  14. refactor: controller 테스트 변경

    - 데이터를 하나하나 비교하는 방법에서 contentType 를 비교하는 테스트로 변경
    donggi-lee-bit committed Apr 12, 2022
    Configuration menu
    Copy the full SHA
    fa44b3c View commit details
    Browse the repository at this point in the history
  15. refactor: 중복 코드 제거 및 Exception 메시지 추가

    - 조건문과 return 문에 있던 중복 코드를 변수로 추출
    - Exception 메시지 추가
    donggi-lee-bit committed Apr 12, 2022
    Configuration menu
    Copy the full SHA
    cbc49b7 View commit details
    Browse the repository at this point in the history
  16. Configuration menu
    Copy the full SHA
    93179f3 View commit details
    Browse the repository at this point in the history
  17. Configuration menu
    Copy the full SHA
    5d99b38 View commit details
    Browse the repository at this point in the history