From e4f20520e411a1c2cd7d22a702c60c6ca5444066 Mon Sep 17 00:00:00 2001 From: chaeyoungeee Date: Wed, 24 Jul 2024 18:20:58 +0900 Subject: [PATCH] =?UTF-8?q?test:=20=ED=9A=8C=EC=9B=90=EA=B0=80=EC=9E=85=20?= =?UTF-8?q?=ED=85=8C=EC=8A=A4=ED=8A=B8=EC=BD=94=EB=93=9C=20=EC=82=AD?= =?UTF-8?q?=EC=A0=9C?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../service/member/LoginServiceTest.java | 54 ------------------- 1 file changed, 54 deletions(-) delete mode 100644 src/test/java/likelion/MZConnent/service/member/LoginServiceTest.java diff --git a/src/test/java/likelion/MZConnent/service/member/LoginServiceTest.java b/src/test/java/likelion/MZConnent/service/member/LoginServiceTest.java deleted file mode 100644 index 6858698..0000000 --- a/src/test/java/likelion/MZConnent/service/member/LoginServiceTest.java +++ /dev/null @@ -1,54 +0,0 @@ -package likelion.MZConnent.service.member; - -import likelion.MZConnent.domain.member.Age; -import likelion.MZConnent.domain.member.Gender; -import likelion.MZConnent.domain.member.Member; -import likelion.MZConnent.dto.member.CreateMemberRequest; -import likelion.MZConnent.repository.member.MemberRepository; -import lombok.extern.slf4j.Slf4j; -import org.junit.jupiter.api.Assertions; -import org.junit.jupiter.api.Test; -import org.springframework.beans.factory.annotation.Autowired; -import org.springframework.boot.test.context.SpringBootTest; -import org.springframework.test.annotation.Rollback; -import org.springframework.transaction.annotation.Transactional; - -import java.util.ArrayList; -import java.util.Arrays; - - -@SpringBootTest -@Slf4j -@Rollback -class LoginServiceTest { - @Autowired - LoginService loginService; - - @Autowired - MemberRepository memberRepository; - - @Test - @Transactional - void createMember() throws Exception { - //given - CreateMemberRequest request = CreateMemberRequest.builder() - .email("aa@test.ac.kr") - .password("test1234@!!") - .realname("테스트") - .username("안녕") - .age(Age.FOURTH_GRADE) - .gender(Gender.FEMALE) - .instagramId("insta") - .facebookId("facebook") - .selfIntroductions(new ArrayList<>(Arrays.asList(1L, 2L, 3L))) - .build(); - - //when - Long memberId = loginService.createUser(request); - Member member = memberRepository.findById(memberId).get(); - - //then - log.info("member: {}", member); - Assertions.assertEquals(memberId, member.getId()); - } -} \ No newline at end of file