### Question:
OrderController extends RestActionSupport implements ModelDriven<Object> { public HttpHeaders create() { log.debug("Create new order: {}", model); ordersService.save(model); return new DefaultHttpHeaders("success") .setLocationId(model.getId()); }  HttpHeaders show(); HttpHeaders index(); String destroy(); HttpHeaders create(); String update(); void setId(String id); Object getModel();  }### Answer:
@Test public void testCreate() throws Exception { request.setParameter("clientName", "Grace Hopper"); request.setParameter("amount", "85"); ActionProxy proxy = getActionProxy("POST", "/data/order.json"); OrderController orderController = (OrderController) proxy.getAction(); proxy.execute(); assertThat(orderController.hasFieldErrors(), is(false)); Object model = orderController.getModel(); assertThat(model, notNullValue()); assertThat(model, is(instanceOf(Order.class))); Order order = (Order) model; assertThat(order.getClientName(), is(equalTo("Grace Hopper"))); assertThat(order.getAmount(), is(equalTo(85))); }