• 카테고리

    질문 & 답변
  • 세부 분야

    백엔드

  • 해결 여부

    미해결

MemberServiceIntegrationTest 에러

23.06.12 00:59 작성 조회수 3.77k

1

MemberServiceIntegrationTest 회원가입 실행 했더니

  1. 00:48:24.902 [main] INFO org.springframework.test.context.support.AnnotationConfigContextLoaderUtils -- Could not detect default configuration classes for test class [hello.hellospring.service.MemberServiceIntegrationTest]: MemberServiceIntegrationTest does not declare any static, non-private, non-final, nested classes annotated with @Configuration.

  2. 00:48:24.954 [main] INFO org.springframework.boot.test.context.SpringBootTestContextBootstrapper -- Found @SpringBootConfiguration hello.hellospring.HelloSpringApplication for test class hello.hellospring.service.MemberServiceIntegrationTest

  3. Java HotSpot(TM) 64-Bit Server VM warning: Sharing is only supported for boot loader classes because bootstrap classpath has been appended

에러가 발생하는데 어떻게 해결을 해야 할지 모르겠습니다.

spring boot version : 3.1.0 입니다.


dependencies {
implementation 'org.springframework.boot:spring-boot-starter-thymeleaf'
implementation 'org.springframework.boot:spring-boot-starter-web'
implementation 'org.springframework.boot:spring-boot-starter-jdbc'
runtimeOnly 'com.h2database:h2'
testImplementation 'org.springframework.boot:spring-boot-starter-test'
}

이렇게 설정되어있습니다.

 

 

 

답변 1

답변을 작성해보세요.

4

OMG님의 프로필

OMG

2023.06.12

안녕하세요. 주종현님, 공식 서포터즈 OMG입니다.

올리신 로그 메시지에 따르면 테스트 실패나 에러가 보이지 않습니다. "Could not detect default configuration classes for test class..." 메시지는 Spring이 @Configuration 어노테이션이 적용된 클래스를 테스트 클래스에서 찾지 못했다는 것을 의미하지만, 이는 경고 수준의 메시지이며, 테스트 실행에 실패하는 원인이 되지는 않습니다.

"Java HotSpot(TM) 64-Bit Server VM warning: Sharing is only supported for boot loader classes because bootstrap classpath has been appended" 는 JVM의 경고로, Java 9 이상에서 발생할 수 있는 문제입니다. 일반적으로 이 경고 메시지는 애플리케이션의 실행에 영향을 미치지 않습니다.

문제라고 생각하시는 부분을 화면캡쳐(최대한 많은 정보를 담을 수 있게 전체 화면으로) 그리고 기대했던 결과와 실제 결과 등의 추가 정보를 올리시면 확인 후 답변 드릴 수 있을 것 같습니다.

감사합니다.