}
@Test(expected = SecurityException.class)
public void updateCategory_invalidToken(){
Model model = new ExtendedModelMap();
User user = new UserImpl();
String id = "1";
String categoryText = "Social";
String invalidToken = AdminControllerUtil.generateSessionToken();
CategoryImpl category = new CategoryImpl();
category.setCreatedUserId(user.getId());
category.setText(categoryText);
category.setId(id);
SessionStatus sessionStatus = createMock(SessionStatus.class);
expect(userService.getAuthenticatedUser()).andReturn(user).once();
expect(categoryService.get(id)).andReturn(category);