[JPA] detached entity passed to persist 오류
분명 다른 클래스에서 작업할 때 Intellij의 자동으로 추가하는 improt 기능이 알아서 해준 것 같은데.. 지금은 오류를 뱉는다.
Cannot resolve method 'assertThat(HttpStatus)'
라고 오류를 표시한다. 지금은 improt가
import static org.junit.Assert.assertThat;
로 되어있는데, 이것 말고 아래를 추가해 준다.
import static org.assertj.core.api.Assertions.assertThat;
관련 내용 https://www.goodsource.co.kr/44