public void testCreateInstance2() throws Exception {
final InstanceSettings instanceSettings = new InstanceSettings(0, 0, 0, null, null,
Collections.<String>emptyList(), Collections.<String>emptyList(), "localhost");
InstanceService instanceService = EasyMock.createMock(InstanceService.class);
EasyMock.expect(instanceService.createInstance("t1", instanceSettings, false)).andReturn(null);
EasyMock.replay(instanceService);
InstancesMBean ab = new InstancesMBeanImpl(instanceService);
assertEquals(-1, ab.createInstance("t1", 0, 0, 0, "", "", "", ""));
}