command.execute(session);
}
@Test
public void testCreatePoolWithTemplate() {
final PoolTemplate template = XmlTemplate.newXmlTemplate(readDefaultTemplate("test-1"));
CreatePoolCommand command = newPoolCommandWithMockedAdminAccess(template);
command.setId("service");
command.setKey("key");
command.setTemplate(template.getId());
Provisionr service = mock(Provisionr.class);
Provider provider = newProviderMockWithBuilder();
when(service.getDefaultProvider()).thenReturn(Optional.of(provider));