Skip to content

Commit

Permalink
fix: 테스트 실행 불가 해결
Browse files Browse the repository at this point in the history
  • Loading branch information
ymkim97 committed Nov 3, 2023
1 parent a24e88f commit 28288e9
Show file tree
Hide file tree
Showing 4 changed files with 11 additions and 27 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,6 @@
import org.springframework.boot.test.autoconfigure.web.servlet.AutoConfigureMockMvc;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.boot.test.mock.mockito.MockBean;
import org.springframework.test.context.ActiveProfiles;
import org.springframework.test.web.servlet.MockMvc;

import com.fasterxml.jackson.databind.ObjectMapper;
Expand All @@ -24,7 +23,6 @@

@SpringBootTest
@AutoConfigureMockMvc
@ActiveProfiles("test")
class BugControllerTest {

@Autowired
Expand Down
Original file line number Diff line number Diff line change
@@ -1,18 +1,11 @@
package com.moabam.api.presentation;

import static com.moabam.global.common.util.OAuthParameterNames.CLIENT_ID;
import static com.moabam.global.common.util.OAuthParameterNames.CLIENT_SECRET;
import static com.moabam.global.common.util.OAuthParameterNames.CODE;
import static com.moabam.global.common.util.OAuthParameterNames.GRANT_TYPE;
import static com.moabam.global.common.util.OAuthParameterNames.REDIRECT_URI;
import static com.moabam.global.common.util.OAuthParameterNames.RESPONSE_TYPE;
import static com.moabam.global.common.util.OAuthParameterNames.SCOPE;
import static org.springframework.test.web.client.match.MockRestRequestMatchers.method;
import static org.springframework.test.web.client.match.MockRestRequestMatchers.requestTo;
import static org.springframework.test.web.client.response.MockRestResponseCreators.withSuccess;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.get;
import static com.moabam.global.common.util.OAuthParameterNames.*;
import static org.springframework.test.web.client.match.MockRestRequestMatchers.*;
import static org.springframework.test.web.client.response.MockRestResponseCreators.*;
import static org.springframework.test.web.servlet.request.MockMvcRequestBuilders.*;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.header;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.status;
import static org.springframework.test.web.servlet.result.MockMvcResultMatchers.*;

import org.junit.jupiter.api.BeforeAll;
import org.junit.jupiter.api.BeforeEach;
Expand All @@ -23,7 +16,6 @@
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.http.HttpMethod;
import org.springframework.http.MediaType;
import org.springframework.test.context.ActiveProfiles;
import org.springframework.test.util.ReflectionTestUtils;
import org.springframework.test.web.client.MockRestServiceServer;
import org.springframework.test.web.client.match.MockRestRequestMatchers;
Expand All @@ -44,7 +36,6 @@

@SpringBootTest
@AutoConfigureMockMvc
@ActiveProfiles("test")
class MemberControllerTest {

@Autowired
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,6 @@
import org.springframework.boot.test.autoconfigure.web.servlet.AutoConfigureMockMvc;
import org.springframework.boot.test.context.SpringBootTest;
import org.springframework.boot.test.mock.mockito.MockBean;
import org.springframework.test.context.ActiveProfiles;
import org.springframework.test.web.servlet.MockMvc;

import com.fasterxml.jackson.databind.ObjectMapper;
Expand All @@ -27,7 +26,6 @@

@SpringBootTest
@AutoConfigureMockMvc
@ActiveProfiles("test")
class ProductControllerTest {

@Autowired
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,12 @@ spring:
hibernate:
format_sql: true

# Redis
data:
redis:
host: 127.0.0.1
port: 6379

oauth2:
client:
provider: test
Expand All @@ -22,12 +28,3 @@ oauth2:
authorization_uri: https://authorization.com/test/test
redirect_uri: http://redirect:8080/test
token_uri: https://token.com/test/test

# Spring
spring:

# Redis
data:
redis:
host: 127.0.0.1
port: 6379

0 comments on commit 28288e9

Please sign in to comment.