mirror of https://github.com/apache/jclouds.git
fixed test parameters
This commit is contained in:
parent
aefc0119ab
commit
a9a46e0f49
|
@ -31,8 +31,8 @@ import org.jclouds.logging.log4j.config.Log4JLoggingModule;
|
||||||
import org.jclouds.rest.RestContext;
|
import org.jclouds.rest.RestContext;
|
||||||
import org.jclouds.vcloud.domain.Catalog;
|
import org.jclouds.vcloud.domain.Catalog;
|
||||||
import org.jclouds.vcloud.domain.CatalogItem;
|
import org.jclouds.vcloud.domain.CatalogItem;
|
||||||
import org.jclouds.vcloud.domain.ReferenceType;
|
|
||||||
import org.jclouds.vcloud.domain.Org;
|
import org.jclouds.vcloud.domain.Org;
|
||||||
|
import org.jclouds.vcloud.domain.ReferenceType;
|
||||||
import org.jclouds.vcloud.domain.Task;
|
import org.jclouds.vcloud.domain.Task;
|
||||||
import org.jclouds.vcloud.domain.VDC;
|
import org.jclouds.vcloud.domain.VDC;
|
||||||
import org.jclouds.vcloud.domain.network.OrgNetwork;
|
import org.jclouds.vcloud.domain.network.OrgNetwork;
|
||||||
|
@ -132,7 +132,7 @@ public abstract class CommonVCloudClientLiveTest<S extends CommonVCloudClient, A
|
||||||
for (ReferenceType resource : response.values()) {
|
for (ReferenceType resource : response.values()) {
|
||||||
if (resource.getType().equals(VCloudMediaType.CATALOGITEM_XML)) {
|
if (resource.getType().equals(VCloudMediaType.CATALOGITEM_XML)) {
|
||||||
CatalogItem item = connection.findCatalogItemInOrgCatalogNamed(org.getName(), response.getName(),
|
CatalogItem item = connection.findCatalogItemInOrgCatalogNamed(org.getName(), response.getName(),
|
||||||
resource.getName());
|
resource.getName());
|
||||||
verifyCatalogItem(item);
|
verifyCatalogItem(item);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
@ -183,10 +183,9 @@ public abstract class CommonVCloudClientLiveTest<S extends CommonVCloudClient, A
|
||||||
protected void setupCredentials() {
|
protected void setupCredentials() {
|
||||||
identity = checkNotNull(System.getProperty("test." + provider + ".identity"), "test." + provider + ".identity");
|
identity = checkNotNull(System.getProperty("test." + provider + ".identity"), "test." + provider + ".identity");
|
||||||
credential = checkNotNull(System.getProperty("test." + provider + ".credential"), "test." + provider
|
credential = checkNotNull(System.getProperty("test." + provider + ".credential"), "test." + provider
|
||||||
+ ".credential");
|
+ ".identity");
|
||||||
endpoint = checkNotNull(System.getProperty("test." + provider + ".endpoint"), "test." + provider + ".endpoint");
|
endpoint = System.getProperty("test." + provider + ".endpoint");
|
||||||
apiversion = checkNotNull(System.getProperty("test." + provider + ".apiversion"), "test." + provider
|
apiversion = System.getProperty("test." + provider + ".apiversion");
|
||||||
+ ".apiversion");
|
|
||||||
}
|
}
|
||||||
|
|
||||||
protected Properties setupProperties() {
|
protected Properties setupProperties() {
|
||||||
|
@ -195,8 +194,10 @@ public abstract class CommonVCloudClientLiveTest<S extends CommonVCloudClient, A
|
||||||
overrides.setProperty(Constants.PROPERTY_RELAX_HOSTNAME, "true");
|
overrides.setProperty(Constants.PROPERTY_RELAX_HOSTNAME, "true");
|
||||||
overrides.setProperty(provider + ".identity", identity);
|
overrides.setProperty(provider + ".identity", identity);
|
||||||
overrides.setProperty(provider + ".credential", credential);
|
overrides.setProperty(provider + ".credential", credential);
|
||||||
overrides.setProperty(provider + ".endpoint", endpoint);
|
if (endpoint != null)
|
||||||
overrides.setProperty(provider + ".apiversion", apiversion);
|
overrides.setProperty(provider + ".endpoint", endpoint);
|
||||||
|
if (apiversion != null)
|
||||||
|
overrides.setProperty(provider + ".apiversion", apiversion);
|
||||||
return overrides;
|
return overrides;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -205,7 +206,7 @@ public abstract class CommonVCloudClientLiveTest<S extends CommonVCloudClient, A
|
||||||
setupCredentials();
|
setupCredentials();
|
||||||
Properties overrides = setupProperties();
|
Properties overrides = setupProperties();
|
||||||
context = new ComputeServiceContextFactory().createContext(provider,
|
context = new ComputeServiceContextFactory().createContext(provider,
|
||||||
ImmutableSet.<Module> of(new Log4JLoggingModule()), overrides).getProviderSpecificContext();
|
ImmutableSet.<Module> of(new Log4JLoggingModule()), overrides).getProviderSpecificContext();
|
||||||
|
|
||||||
connection = context.getApi();
|
connection = context.getApi();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue