@Test
public void testNewSpace() throws GoalConfigurationException, GoalExecutionException {

  // Mock REST services
  this.configureBackendServiceUrl(server);
  this.setupMockSpaceServices(testSpace);
  // Set config
  this.vulasConfiguration.setProperty(
      CoreConfiguration.TENANT_TOKEN, testTenant.getTenantToken());
  this.vulasConfiguration.setProperty(CoreConfiguration.SPACE_NAME, testSpace.getSpaceName());
  this.vulasConfiguration.setProperty(
      CoreConfiguration.SPACE_DESCR, testSpace.getSpaceDescription());
  // Execute goal
  final AbstractGoal goal = GoalFactory.create(GoalType.SPACENEW, GoalClient.CLI);
  goal.setConfiguration(this.vulasConfiguration).executeSync();
  final Space new_space = (Space) goal.getResultObject();
  assertEquals(testSpace, new_space);
  // Check the HTTP calls made
  verifyHttp(server).times(1, method(Method.POST), uri("/backend" + PathBuilder.spaces()));
  verifyHttp(server)
      .times(
          0,
          method(Method.POST),
          uri("/backend" + PathBuilder.goalExcecutions(null, testSpace, null)));
}