Skip to content

Commit

Permalink
refactor : test naming 변경
Browse files Browse the repository at this point in the history
  • Loading branch information
david-parkk committed Jun 7, 2024
1 parent 43622e8 commit e1259ee
Show file tree
Hide file tree
Showing 4 changed files with 10 additions and 7 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@
import static org.junit.jupiter.api.Assertions.*;

@SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT)
@DisplayName("[Integration Test] -Map Websocket Test")
public class MapWebsocketTest {

@LocalServerPort
Expand All @@ -61,7 +62,7 @@ public void initDB() {
.verifyComplete();
}

@DisplayName("[integration test] 저장된 map 유저 정보를 websocket로 받아야 한다.")
@DisplayName("저장된 map 유저 정보를 websocket로 받아야 한다.")
@Test
public void test1() throws URISyntaxException {
int connectionTimeSecond=1;
Expand All @@ -83,7 +84,7 @@ public void test1() throws URISyntaxException {
assertTrue(actualMessage.contains(expectedMessage));
}

@DisplayName("[integration test] 저장된 map 유저 정보중 NOTUSE 유저는 websocket로 받을 수 없다.")
@DisplayName("저장된 map 유저 정보중 NOTUSE 유저는 websocket로 받을 수 없다.")
@Test
public void test2() throws URISyntaxException {
userRepository.delete(user1.getUserId()).block();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@
import java.time.Duration;

@SpringBootTest(webEnvironment = SpringBootTest.WebEnvironment.RANDOM_PORT)
@DisplayName("[Integration Test] -Map Controller Test")
public class UserControllerTest {

@Autowired
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@

@ExtendWith(SpringExtension.class)
@WebFluxTest(controllers = UserController.class)
@DisplayName("[Unit Test] -API Test")
public class RedisUserControllerAPITest {

@Autowired
Expand All @@ -55,7 +56,7 @@ public class RedisUserControllerAPITest {
GetMapUserResponse getMapUserResponse2 = GetMapUserResponse.toDto(user2);

@Test
@DisplayName("unit test-API test user를 저장했을 때 user에 대한 return 값을 받아 와야 한다. " +
@DisplayName("user를 저장했을 때 user에 대한 return 값을 받아 와야 한다. " +
"작업이 필요합니다")
public void test1() {

Expand All @@ -76,7 +77,7 @@ public void test1() {
}

@Test
@DisplayName("unit test-API test 저장된 유저를 찾아야한다.")
@DisplayName("저장된 유저를 찾아야한다.")
public void test2() {

//given
Expand All @@ -94,7 +95,7 @@ public void test2() {
}

@Test
@DisplayName("unit test-API test 저장된 모든 유저를 찾을 수 있어야한다.")
@DisplayName("저장된 모든 유저를 찾을 수 있어야한다.")
public void test3() {

//given
Expand All @@ -116,7 +117,7 @@ public void test3() {
}

@Test
@DisplayName("unit test-API test 유저를 삭제할 수 있어야한다.")
@DisplayName("유저를 삭제할 수 있어야한다.")
public void test4() {

//given
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@
@ExtendWith(SpringExtension.class)
@WebFluxTest(controllers = UserController.class)
@Import(RedisUserController.class)//현재에는 필요 없는 것 같다
@DisplayName("unit test-controller test")
@DisplayName("[Unit test] -Controller test")
public class RedisUserControllerTest {

@MockBean
Expand Down

0 comments on commit e1259ee

Please sign in to comment.