### Question:
DataObjectModelController { public void setDataObjectModelValidator(DataObjectModelValidator dataObjectModelValidator) { this.dataObjectModelValidator = dataObjectModelValidator; }  IDataObjectModelService getDataObjectModelService(); void setDataObjectModelService(IDataObjectModelService dataObjectModelService); DataObjectModelValidator getDataObjectModelValidator(); void setDataObjectModelValidator(DataObjectModelValidator dataObjectModelValidator); @RestAccessControl(permission = Permission.SUPERUSER) @RequestMapping(method = RequestMethod.GET, produces = MediaType.APPLICATION_JSON_VALUE) ResponseEntity<PagedRestResponse<DataModelDto>> getDataObjectModels(RestListRequest requestList); @RestAccessControl(permission = Permission.SUPERUSER) @RequestMapping(value = "/{dataModelId}", method = RequestMethod.GET, produces = MediaType.APPLICATION_JSON_VALUE) ResponseEntity<SimpleRestResponse<DataModelDto>> getDataObjectModel(@PathVariable String dataModelId); @RestAccessControl(permission = Permission.SUPERUSER) @RequestMapping(method = RequestMethod.POST, produces = MediaType.APPLICATION_JSON_VALUE) ResponseEntity<SimpleRestResponse<DataModelDto>> addDataObjectModel(@Valid @RequestBody DataObjectModelRequest dataObjectModelRequest,
            BindingResult bindingResult); @RestAccessControl(permission = Permission.SUPERUSER) @RequestMapping(value = "/{dataModelId}", method = RequestMethod.PUT, produces = MediaType.APPLICATION_JSON_VALUE) ResponseEntity<SimpleRestResponse<DataModelDto>> updateDataObjectModel(@PathVariable String dataModelId,
            @Valid @RequestBody DataObjectModelRequest dataObjectModelRequest, BindingResult bindingResult); @RestAccessControl(permission = Permission.SUPERUSER) @RequestMapping(value = "/{dataModelId}", method = RequestMethod.PATCH, produces = MediaType.APPLICATION_JSON_VALUE, consumes="application/json-patch+json") ResponseEntity<SimpleRestResponse<DataModelDto>> patchDataObjectModel(@PathVariable Long dataModelId,
                                                                                 @RequestBody JsonNode jsonPatch,
                                                                                 BindingResult bindingResult); @RestAccessControl(permission = Permission.SUPERUSER) @RequestMapping(value = "/{dataModelId}", method = RequestMethod.DELETE, produces = MediaType.APPLICATION_JSON_VALUE) ResponseEntity<SimpleRestResponse<Map>> deleteDataObjectModel(@PathVariable String dataModelId); @RestAccessControl(permission = Permission.SUPERUSER) @RequestMapping(value = "/dictionary", method = RequestMethod.GET, produces = MediaType.APPLICATION_JSON_VALUE) ResponseEntity<SimpleRestResponse<IEntityModelDictionary>> getDictionary(@RequestParam(value = "typeCode", required = false) String typeCode);  }### Answer:
@Test public void should_validate_put_path_mismatch() throws ApsSystemException, Exception { UserDetails user = new OAuth2TestUtils.UserBuilder("jack_bauer", "0x24").grantedToRoleAdmin().build(); String accessToken = mockOAuthInterceptor(user); ObjectMapper mapper = new ObjectMapper(); DataObjectModelRequest group = new DataObjectModelRequest(); group.setModelId("2l"); group.setDescr("Description"); group.setType("AAA"); group.setModel("<p>Test</p>"); String payload = mapper.writeValueAsString(group); this.controller.setDataObjectModelValidator(new DataObjectModelValidator()); ResultActions result = mockMvc.perform(put("/dataModels/{dataModelId}", "67") .content(payload) .contentType(MediaType.APPLICATION_JSON) .header("Authorization", "Bearer " + accessToken)); result.andExpect(status().isBadRequest()); }