@@ -472,8 +472,8 @@ public void testMultiplePojoRequestParts() {
472472 Hello pojo2 = new Hello (OI_TERRA_2 );
473473 MockMultipartFile file = new MockMultipartFile ("file" , "hello.bin" , null ,
474474 "hello" .getBytes ());
475- String response = this .multipartClient .multipartPojo (pojo1 , pojo2 , file );
476- assertThat (response ).isEqualTo ("hello world 1oi terra 2hello.bin" );
475+ String response = this .multipartClient .multipartPojo ("abc" , "123" , pojo1 , pojo2 , file );
476+ assertThat (response ).isEqualTo ("abc123hello world 1oi terra 2hello.bin" );
477477 }
478478
479479 @ Test
@@ -704,7 +704,9 @@ String multipart(@RequestPart("hello") String hello,
704704 @ RequestMapping (method = RequestMethod .POST , path = "/multipartPojo" ,
705705 consumes = MediaType .MULTIPART_FORM_DATA_VALUE ,
706706 produces = MediaType .TEXT_PLAIN_VALUE )
707- String multipartPojo (@ RequestPart ("pojo1" ) Hello pojo1 ,
707+ String multipartPojo (@ RequestPart ("hello" ) String hello ,
708+ @ RequestPart ("world" ) String world ,
709+ @ RequestPart ("pojo1" ) Hello pojo1 ,
708710 @ RequestPart ("pojo2" ) Hello pojo2 ,
709711 @ RequestPart ("file" ) MultipartFile file );
710712
@@ -1087,10 +1089,12 @@ String multipart(@RequestPart("hello") String hello,
10871089 @ RequestMapping (method = RequestMethod .POST , path = "/multipartPojo" ,
10881090 consumes = MediaType .MULTIPART_FORM_DATA_VALUE ,
10891091 produces = MediaType .TEXT_PLAIN_VALUE )
1090- String multipartPojo (@ RequestPart ("pojo1" ) Hello pojo1 ,
1092+ String multipartPojo (@ RequestPart ("hello" ) String hello ,
1093+ @ RequestPart ("world" ) String world ,
1094+ @ RequestPart ("pojo1" ) Hello pojo1 ,
10911095 @ RequestPart ("pojo2" ) Hello pojo2 ,
10921096 @ RequestPart ("file" ) MultipartFile file ) {
1093- return pojo1 .getMessage () + pojo2 .getMessage () + file .getOriginalFilename ();
1097+ return hello + world + pojo1 .getMessage () + pojo2 .getMessage () + file .getOriginalFilename ();
10941098 }
10951099
10961100 @ RequestMapping (method = RequestMethod .POST , path = "/multipartNames" ,
0 commit comments