@Test
public void testBadAgentServerGroupSanitization() throws Exception {

    AgentInstanceGroup agentInstanceGroup = AgentGenerator.agentServerGroups().getValue().toBuilder()
            .withId("    myId    ")
            .withMin(10)
            .withDesired(5)
            .withMax(1)
            .build();
    assertThat(sanitizer.sanitize(agentInstanceGroup).get().getId()).isEqualTo("myId");
    assertThat(sanitizer.validate(agentInstanceGroup)).hasSize(2);
}