String payload = Strings2.toStringAndClose(newRequest.getPayload().getInput());
assertEquals(payload, "{\"groupname\":\"foo\",\"actors\":{\"clients\":[],\"groups\":[],\"users\":[]}}");
}
public void testBindNameAndLists() throws IOException {
Group group = new Group("foo");
group.setClients(ImmutableSet.of("nacx-validator"));
group.setGroups(ImmutableSet.of("admins"));
group.setUsers(ImmutableSet.of("nacx"));
HttpRequest request = HttpRequest.builder().method("POST").endpoint(URI.create("http://localhost")).build();
HttpRequest newRequest = binder.bindToRequest(request, group);
String payload = Strings2.toStringAndClose(newRequest.getPayload().getInput());