Closed jongmee closed 2 months ago
์ด๋ฏธ ์์ฑํ Recruitment๋ฅผ update saveํ ๋ ์ฐ๊ด๊ด๊ณ์ ์๋ ์ํฐํฐ๋ค์ด ์์ ๋์ง ์๊ณ ์๋ก ์์ฑ๋๋ค.
๊ด๋ จ ํ ์คํธ: ์ ๋ฐ์ดํธ ๋ ์ง๋ฌธ์ id ๊ฐ์ด ๊ธฐ์กด์ ์ ์ฅ๋ ์ง๋ฌธ์ id ๊ฐ๊ณผ ๋ค๋ฅด๋ค.
@Test @DisplayName("์ง์์ ์์์ ์์ ์ ์ฅํ๋ค.") void updateRecruitment() { // given Administrator publisher = LIKE_LION_ADMIN().administrator(); RecruitmentDetailsResponse savedRecruitmentResponse = recruitmentService.saveRecruitment(publisher.getId(), RECRUITMENT_SAVE_REQUEST); SectionsSaveRequest newSectionSaveRequest = new SectionsSaveRequest("์๋ก์ด ์น์ ์ด๋ฆ", DEFAULT_DESCRIPTION, QUESTION_REQUESTS); RecruitmentSaveRequest recruitmentSaveRequest = new RecruitmentSaveRequest(RECRUITMENT_SAVE_REQUEST.title(), RECRUITMENT_SAVE_REQUEST.description(), List.of(newSectionSaveRequest, FRONTEND_SECTION_REQUEST), DEFAULT_CLOSING_DATE.toString()); // when RecruitmentDetailsResponse response = recruitmentService.saveRecruitment(publisher.getId(), recruitmentSaveRequest); // then List<Long> savedSelectiveQuestionIds = extractSelectiveQuestionIds(savedRecruitmentResponse); assertAll(() -> { assertThat(response.id()).isEqualTo(savedRecruitmentResponse.id()); assertThat(response.sections()).extracting(SectionResponse::name).contains("์๋ก์ด ์น์ ์ด๋ฆ"); assertThat(extractSelectiveQuestionIds(response)).containsAll(savedSelectiveQuestionIds); }); }
Problem ๐
๊ด๋ จ ํ ์คํธ: ์ ๋ฐ์ดํธ ๋ ์ง๋ฌธ์ id ๊ฐ์ด ๊ธฐ์กด์ ์ ์ฅ๋ ์ง๋ฌธ์ id ๊ฐ๊ณผ ๋ค๋ฅด๋ค.
Progress ๐ข