Merge pull request #11982 from anuragkumawat/JAVA-9809
JAVA-10922 Fix RestTemplateBasicLiveTest in spring-resttemplate module
This commit is contained in:
commit
3f3376d8d2
|
@ -9,6 +9,7 @@ import java.util.Map;
|
||||||
import com.baeldung.resttemplate.web.dto.Foo;
|
import com.baeldung.resttemplate.web.dto.Foo;
|
||||||
import org.springframework.http.HttpHeaders;
|
import org.springframework.http.HttpHeaders;
|
||||||
import org.springframework.http.HttpStatus;
|
import org.springframework.http.HttpStatus;
|
||||||
|
import org.springframework.http.MediaType;
|
||||||
import org.springframework.http.ResponseEntity;
|
import org.springframework.http.ResponseEntity;
|
||||||
import org.springframework.stereotype.Controller;
|
import org.springframework.stereotype.Controller;
|
||||||
import org.springframework.web.bind.annotation.PathVariable;
|
import org.springframework.web.bind.annotation.PathVariable;
|
||||||
|
@ -114,7 +115,7 @@ public class FooController {
|
||||||
return id;
|
return id;
|
||||||
}
|
}
|
||||||
|
|
||||||
@RequestMapping(method = RequestMethod.POST, value = "/foos/form")
|
@RequestMapping(method = RequestMethod.POST, value = "/foos/form", produces = MediaType.TEXT_PLAIN_VALUE)
|
||||||
@ResponseStatus(HttpStatus.CREATED)
|
@ResponseStatus(HttpStatus.CREATED)
|
||||||
@ResponseBody
|
@ResponseBody
|
||||||
public String submitFoo(@RequestParam("id") String id) {
|
public String submitFoo(@RequestParam("id") String id) {
|
||||||
|
|
Loading…
Reference in New Issue