Add tests for change password, remove user. All admin operations covered.

This commit is contained in:
Paulo Gustavo Veiga
2012-03-12 13:50:43 -03:00
parent 1aebcf48e3
commit 3f2deda442
2 changed files with 86 additions and 13 deletions

View File

@@ -72,7 +72,7 @@ public class AdminController extends BaseController {
response.setHeader("Location","/service/admin/users/" + user.getId());
}
@RequestMapping(method = RequestMethod.PUT, value = "admin/users/{id}/password", consumes = {"text/plain"}, produces = {"application/json", "text/html", "application/xml"})
@RequestMapping(method = RequestMethod.PUT, value = "admin/users/{id}/password", consumes = {"text/plain"})
@ResponseStatus(value = HttpStatus.NO_CONTENT)
public void changePassword(@RequestBody String password, @PathVariable long id) throws IOException, WiseMappingException {
if (password == null) {