Skip to content

Commit

Permalink
refactor: 요청 메서드 타입 변경
Browse files Browse the repository at this point in the history
  • Loading branch information
JJ503 committed Sep 18, 2023
1 parent 237d2ee commit b2122bf
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 4 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,6 @@
import lombok.RequiredArgsConstructor;
import org.springframework.http.HttpHeaders;
import org.springframework.http.ResponseEntity;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.PostMapping;
Expand Down Expand Up @@ -68,7 +67,7 @@ public ResponseEntity<Void> logout(
.build();
}

@DeleteMapping("/withdrawal/{oauth2Type}")
@PostMapping("/withdrawal/{oauth2Type}")
public ResponseEntity<Void> withdrawal(
@PathVariable final Oauth2Type oauth2Type,
@RequestHeader(HttpHeaders.AUTHORIZATION) final String accessToken,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -203,7 +203,6 @@ void setUp(@Autowired RestDocumentationContextProvider provider) {
)
)
);
;
}

@Test
Expand Down Expand Up @@ -336,7 +335,7 @@ void setUp(@Autowired RestDocumentationContextProvider provider) {
.withdrawal(any(), anyString(), anyString());

// when & then
mockMvc.perform(RestDocumentationRequestBuilders.delete("/oauth2/withdrawal/{oauth2Type}", "kakao")
mockMvc.perform(RestDocumentationRequestBuilders.post("/oauth2/withdrawal/{oauth2Type}", "kakao")
.contentType(MediaType.APPLICATION_JSON)
.content(objectMapper.writeValueAsString(request))
.header(HttpHeaders.AUTHORIZATION, "Bearer accessToken")
Expand Down

0 comments on commit b2122bf

Please sign in to comment.