Issue 550: added loadbalancer, table, and queue types

This commit is contained in:
Adrian Cole 2011-05-16 22:55:56 -07:00
parent ba12d4add5
commit c880c057b1
4 changed files with 6 additions and 42 deletions

View File

@ -33,6 +33,9 @@ public interface ProviderMetadata {
public static final String BLOBSTORE_TYPE = "blobstore"; public static final String BLOBSTORE_TYPE = "blobstore";
public static final String COMPUTE_TYPE = "compute"; public static final String COMPUTE_TYPE = "compute";
public static final String LOADBALANCER_TYPE = "loadbalancer";
public static final String TABLE_TYPE = "table";
public static final String QUEUE_TYPE = "queue";
/** /**
* *

View File

@ -34,7 +34,8 @@ import com.google.common.collect.Sets;
*/ */
@Test(groups = "unit") @Test(groups = "unit")
public abstract class BaseProviderMetadataTest { public abstract class BaseProviderMetadataTest {
protected Set<String> allTypes = ImmutableSet.of(ProviderMetadata.BLOBSTORE_TYPE, ProviderMetadata.COMPUTE_TYPE); protected Set<String> allTypes = ImmutableSet.of(ProviderMetadata.BLOBSTORE_TYPE, ProviderMetadata.COMPUTE_TYPE,
ProviderMetadata.LOADBALANCER_TYPE, ProviderMetadata.QUEUE_TYPE, ProviderMetadata.TABLE_TYPE);
private final ProviderMetadata toTest; private final ProviderMetadata toTest;
private final String expectedType; private final String expectedType;

View File

@ -103,7 +103,7 @@ public class AWSS3ProviderMetadata extends BaseProviderMetadata {
*/ */
@Override @Override
public Set<String> getLinkedServices() { public Set<String> getLinkedServices() {
return ImmutableSet.of(getId(), "aws-ec2"); return ImmutableSet.of("aws-s3", "aws-ec2", "aws-elb", "aws-simpledb");
} }
} }

View File

@ -1,40 +0,0 @@
/**
*
* Copyright (C) 2011 Cloud Conscious, LLC. <info@cloudconscious.com>
*
* ====================================================================
* Licensed under the Apache License, Version 2.0 (the "License");
* you may not use this file except in compliance with the License.
* You may obtain a copy of the License at
*
* http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing, software
* distributed under the License is distributed on an "AS IS" BASIS,
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
* See the License for the specific language governing permissions and
* limitations under the License.
* ====================================================================
*/
package org.jclouds.aws.s3;
import org.jclouds.rest.Providers;
import org.testng.annotations.Test;
import com.google.common.collect.Iterables;
/**
*
* @author Adrian Cole
*
*/
@Test(groups = "unit")
public class ProvidersInPropertiesTest {
@Test
public void testSupportedProviders() {
Iterable<String> providers = Providers.getSupportedProviders();
assert Iterables.contains(providers, "aws-s3") : providers;
}
}