Skip to content

Commit

Permalink
[fix] Http Method 수정
Browse files Browse the repository at this point in the history
  • Loading branch information
kimhyun5u committed Aug 18, 2024
1 parent 9b4a2a2 commit 9b0e736
Showing 1 changed file with 5 additions and 5 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -53,7 +53,7 @@ void testUpdateMenuStock() throws Exception {
given(updateMenuStockService.updateMenuStock(any(UpdateMenuStockCommand.class))).willReturn(menuId);

// when
mockMvc.perform(put("/menus/stock")
mockMvc.perform(patch("/menus/stock")
.contentType(MediaType.APPLICATION_JSON)
.content(objectMapper.writeValueAsString(request))
.session(session))
Expand All @@ -72,7 +72,7 @@ void testUpdateMenuStockFailWithStockUnderZero() throws Exception {
UpdateMenuStockRequest request = new UpdateMenuStockRequest(menuId, stock);

// when
mockMvc.perform(put("/menus/stock")
mockMvc.perform(patch("/menus/stock")
.contentType(MediaType.APPLICATION_JSON)
.content(objectMapper.writeValueAsString(request))
.session(session))
Expand All @@ -90,7 +90,7 @@ void testUpdateMenuStockFailWithMenuIdNull() throws Exception {
UpdateMenuStockRequest request = new UpdateMenuStockRequest(menuId, stock);

// when
mockMvc.perform(put("/menus/stock")
mockMvc.perform(patch("/menus/stock")
.contentType(MediaType.APPLICATION_JSON)
.content(objectMapper.writeValueAsString(request))
.session(session))
Expand Down Expand Up @@ -127,7 +127,7 @@ void testUpdateMenuStockFailWithUnauthorized() throws Exception {
UpdateMenuStockRequest request = new UpdateMenuStockRequest(menuId, stock);

// when
mockMvc.perform(put("/menus/stock")
mockMvc.perform(patch("/menus/stock")
.contentType(MediaType.APPLICATION_JSON)
.content(objectMapper.writeValueAsString(request)))
.andExpect(status().isUnauthorized());
Expand All @@ -147,7 +147,7 @@ void testUpdateMenuStockFailWithStoreNotOpen() throws Exception {
new NotUpdatableTimeException("매장이 열려있습니다."));

// when
mockMvc.perform(put("/menus/stock")
mockMvc.perform(patch("/menus/stock")
.contentType(MediaType.APPLICATION_JSON)
.content(objectMapper.writeValueAsString(request))
.session(session))
Expand Down

0 comments on commit 9b0e736

Please sign in to comment.