Skip to content

Commit

Permalink
fix: RedissonClient spybean으로 할 시 나머지 테스트 실패
Browse files Browse the repository at this point in the history
  • Loading branch information
alstn113 committed Dec 31, 2024
1 parent 206cb65 commit b7f5684
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ class SubmissionServiceTest extends AbstractIntegrationTest {

@Test
@DisplayName("분산 서버에서 레디스를 사용한 분산 락을 이용해서 중복 제출을 방지한다.")
@Disabled("레디스를 사용 중인 환경에서만 작동합니다.")
@Disabled("레디스를 사용 중인 환경에서만 작동합니다. AbstractIntegrationTest의 RedissonClient를 주석 처리해주세요.")
void submit() throws InterruptedException {
// given
Member member1 = memberRepository.save(new Member("[email protected]", GOOGLE, "123", "ex1", "https://ex1.com"));
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
import org.redisson.api.RedissonClient;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.boot.test.context.TestConfiguration;
import org.springframework.boot.test.mock.mockito.SpyBean;
import org.springframework.boot.test.mock.mockito.MockBean;
import org.springframework.context.annotation.Bean;
import org.springframework.test.context.ActiveProfiles;

Expand All @@ -15,7 +15,7 @@
@ActiveProfiles("test")
public abstract class AbstractIntegrationTest {

@SpyBean
@MockBean
protected RedissonClient redissonClient;

@TestConfiguration
Expand Down

0 comments on commit b7f5684

Please sign in to comment.