Merge pull request #105 from jsonking/master

Cloudsigma: Fixed documentation links, plus LiveTest for rename a VLAN which works now
This commit is contained in:
Adrian Cole 2011-10-11 10:20:41 -07:00
commit 5f800efe66
3 changed files with 22 additions and 38 deletions

View File

@ -70,7 +70,7 @@ import com.google.common.util.concurrent.ListenableFuture;
* <p/> * <p/>
* *
* @see CloudSigmaClient * @see CloudSigmaClient
* @see <a href="TODO: insert URL of provider documentation" /> * @see <a href="http://cloudsigma.com/en/platform-details/the-api" />
* @author Adrian Cole * @author Adrian Cole
*/ */
@RequestFilters(BasicAuthentication.class) @RequestFilters(BasicAuthentication.class)

View File

@ -18,31 +18,15 @@
*/ */
package org.jclouds.cloudsigma; package org.jclouds.cloudsigma;
import static com.google.common.base.Preconditions.checkNotNull; import com.google.common.base.Predicate;
import static org.testng.Assert.assertEquals; import com.google.common.base.Predicates;
import static org.testng.Assert.assertNotNull; import com.google.common.collect.ImmutableMap;
import com.google.common.collect.ImmutableSet;
import java.io.IOException; import com.google.gson.Gson;
import java.util.Properties; import com.google.inject.Guice;
import java.util.Set; import com.google.inject.Module;
import java.util.concurrent.TimeUnit;
import java.util.logging.Logger;
import org.jclouds.Constants; import org.jclouds.Constants;
import org.jclouds.cloudsigma.domain.ClaimType; import org.jclouds.cloudsigma.domain.*;
import org.jclouds.cloudsigma.domain.CreateDriveRequest;
import org.jclouds.cloudsigma.domain.DriveData;
import org.jclouds.cloudsigma.domain.DriveInfo;
import org.jclouds.cloudsigma.domain.DriveStatus;
import org.jclouds.cloudsigma.domain.DriveType;
import org.jclouds.cloudsigma.domain.IDEDevice;
import org.jclouds.cloudsigma.domain.Model;
import org.jclouds.cloudsigma.domain.ProfileInfo;
import org.jclouds.cloudsigma.domain.Server;
import org.jclouds.cloudsigma.domain.ServerInfo;
import org.jclouds.cloudsigma.domain.ServerStatus;
import org.jclouds.cloudsigma.domain.StaticIPInfo;
import org.jclouds.cloudsigma.domain.VLANInfo;
import org.jclouds.cloudsigma.options.CloneDriveOptions; import org.jclouds.cloudsigma.options.CloneDriveOptions;
import org.jclouds.cloudsigma.predicates.DriveClaimed; import org.jclouds.cloudsigma.predicates.DriveClaimed;
import org.jclouds.cloudsigma.util.Servers; import org.jclouds.cloudsigma.util.Servers;
@ -60,13 +44,15 @@ import org.testng.annotations.AfterGroups;
import org.testng.annotations.BeforeGroups; import org.testng.annotations.BeforeGroups;
import org.testng.annotations.Test; import org.testng.annotations.Test;
import com.google.common.base.Predicate; import java.io.IOException;
import com.google.common.base.Predicates; import java.util.Properties;
import com.google.common.collect.ImmutableMap; import java.util.Set;
import com.google.common.collect.ImmutableSet; import java.util.concurrent.TimeUnit;
import com.google.gson.Gson; import java.util.logging.Logger;
import com.google.inject.Guice;
import com.google.inject.Module; import static com.google.common.base.Preconditions.checkNotNull;
import static org.testng.Assert.assertEquals;
import static org.testng.Assert.assertNotNull;
/** /**
* Tests behavior of {@code CloudSigmaClient} * Tests behavior of {@code CloudSigmaClient}
@ -273,11 +259,9 @@ public class CloudSigmaClientLiveTest {
vlan = client.getVLANInfo(vlan.getUuid()); vlan = client.getVLANInfo(vlan.getUuid());
assertEquals(vlan.getName(), prefix); assertEquals(vlan.getName(), prefix);
vlan = client.renameVLAN(vlan.getUuid(), prefix + "2"); String prefix2 = prefix + "2";
// test that rename didn't work :) vlan = client.renameVLAN(vlan.getUuid(), prefix2);
assertEquals(vlan.getName(), prefix); assertEquals(vlan.getName(),prefix2);
vlan = client.getVLANInfo(vlan.getUuid());
assertEquals(vlan.getName(), prefix);
} finally { } finally {
client.destroyVLAN(id); client.destroyVLAN(id);
} }

View File

@ -93,7 +93,7 @@ public class CloudSigmaLasVegasProviderMetadata extends BaseProviderMetadata {
*/ */
@Override @Override
public URI getApiDocumentation() { public URI getApiDocumentation() {
return URI.create("http://lvs.cloudsigma.com/en/platform-details/the-api"); return URI.create("http://cloudsigma.com/en/platform-details/the-api");
} }
/** /**