mirror of https://github.com/apache/jclouds.git
fixed demos after stub was renamed
This commit is contained in:
parent
3be3966f45
commit
983801ceb0
|
@ -26,8 +26,8 @@ import java.util.Map;
|
|||
import java.util.concurrent.ExecutionException;
|
||||
|
||||
import org.jclouds.blobstore.BlobStoreContext;
|
||||
import org.jclouds.blobstore.TransientBlobStoreContextBuilder;
|
||||
import org.jclouds.blobstore.domain.Blob;
|
||||
import org.jclouds.blobstore.integration.StubBlobStoreContextBuilder;
|
||||
import org.jclouds.demo.tweetstore.domain.StoredTweetStatus;
|
||||
import org.jclouds.demo.tweetstore.functions.ServiceToStoredTweetStatuses;
|
||||
import org.jclouds.demo.tweetstore.reference.TweetStoreConstants;
|
||||
|
@ -49,7 +49,7 @@ public class AddTweetsControllerTest {
|
|||
ExecutionException {
|
||||
Map<String, BlobStoreContext> services = Maps.newHashMap();
|
||||
for (String name : new String[] { "1", "2" }) {
|
||||
BlobStoreContext context = new StubBlobStoreContextBuilder().buildBlobStoreContext();
|
||||
BlobStoreContext context = new TransientBlobStoreContextBuilder().buildBlobStoreContext();
|
||||
context.getAsyncBlobStore().createContainerInLocation(null, container).get();
|
||||
Blob blob = context.getAsyncBlobStore().newBlob("1");
|
||||
blob.getMetadata().getUserMetadata().put(TweetStoreConstants.SENDER_NAME, "frank");
|
||||
|
|
|
@ -30,8 +30,8 @@ import java.util.concurrent.ExecutionException;
|
|||
|
||||
import org.jclouds.blobstore.BlobMap;
|
||||
import org.jclouds.blobstore.BlobStoreContext;
|
||||
import org.jclouds.blobstore.TransientBlobStoreContextBuilder;
|
||||
import org.jclouds.blobstore.domain.Blob;
|
||||
import org.jclouds.blobstore.integration.StubBlobStoreContextBuilder;
|
||||
import org.jclouds.demo.tweetstore.reference.TweetStoreConstants;
|
||||
import org.jclouds.twitter.TwitterClient;
|
||||
import org.jclouds.twitter.domain.Status;
|
||||
|
@ -56,8 +56,8 @@ public class StoreTweetsControllerTest {
|
|||
|
||||
Map<String, BlobStoreContext> createBlobStores() throws InterruptedException, ExecutionException {
|
||||
Map<String, BlobStoreContext> contexts = ImmutableMap.<String, BlobStoreContext> of("test1",
|
||||
new StubBlobStoreContextBuilder().buildBlobStoreContext(), "test2",
|
||||
new StubBlobStoreContextBuilder().buildBlobStoreContext());
|
||||
new TransientBlobStoreContextBuilder().buildBlobStoreContext(), "test2",
|
||||
new TransientBlobStoreContextBuilder().buildBlobStoreContext());
|
||||
for (BlobStoreContext blobstore : contexts.values()) {
|
||||
blobstore.getAsyncBlobStore().createContainerInLocation(null, "favo").get();
|
||||
}
|
||||
|
|
|
@ -25,8 +25,8 @@ import java.util.concurrent.ExecutionException;
|
|||
|
||||
import org.jclouds.blobstore.BlobMap;
|
||||
import org.jclouds.blobstore.BlobStoreContext;
|
||||
import org.jclouds.blobstore.TransientBlobStoreContextBuilder;
|
||||
import org.jclouds.blobstore.domain.Blob;
|
||||
import org.jclouds.blobstore.integration.StubBlobStoreContextBuilder;
|
||||
import org.jclouds.demo.tweetstore.domain.StoredTweetStatus;
|
||||
import org.jclouds.demo.tweetstore.reference.TweetStoreConstants;
|
||||
import org.testng.annotations.Test;
|
||||
|
@ -40,7 +40,7 @@ import org.testng.annotations.Test;
|
|||
public class KeyToStoredTweetStatusTest {
|
||||
|
||||
BlobMap createMap() throws InterruptedException, ExecutionException {
|
||||
BlobStoreContext context = new StubBlobStoreContextBuilder().buildBlobStoreContext();
|
||||
BlobStoreContext context = new TransientBlobStoreContextBuilder().buildBlobStoreContext();
|
||||
context.getBlobStore().createContainerInLocation(null, "test1");
|
||||
return context.createBlobMap("test1");
|
||||
}
|
||||
|
|
|
@ -25,8 +25,8 @@ import java.util.Map;
|
|||
import java.util.concurrent.ExecutionException;
|
||||
|
||||
import org.jclouds.blobstore.BlobStoreContext;
|
||||
import org.jclouds.blobstore.TransientBlobStoreContextBuilder;
|
||||
import org.jclouds.blobstore.domain.Blob;
|
||||
import org.jclouds.blobstore.integration.StubBlobStoreContextBuilder;
|
||||
import org.jclouds.demo.tweetstore.domain.StoredTweetStatus;
|
||||
import org.jclouds.demo.tweetstore.reference.TweetStoreConstants;
|
||||
import org.testng.annotations.Test;
|
||||
|
@ -46,7 +46,7 @@ public class ServiceToStoredTweetStatusesTest {
|
|||
ExecutionException {
|
||||
Map<String, BlobStoreContext> services = Maps.newHashMap();
|
||||
for (String name : new String[] { "1", "2" }) {
|
||||
BlobStoreContext context = new StubBlobStoreContextBuilder().buildBlobStoreContext();
|
||||
BlobStoreContext context = new TransientBlobStoreContextBuilder().buildBlobStoreContext();
|
||||
context.getAsyncBlobStore().createContainerInLocation(null, container).get();
|
||||
Blob blob = context.getAsyncBlobStore().newBlob("1");
|
||||
blob.getMetadata().getUserMetadata().put(TweetStoreConstants.SENDER_NAME, "frank");
|
||||
|
|
|
@ -26,8 +26,8 @@ import java.util.Map;
|
|||
import java.util.concurrent.ExecutionException;
|
||||
|
||||
import org.jclouds.blobstore.BlobStoreContext;
|
||||
import org.jclouds.blobstore.TransientBlobStoreContextBuilder;
|
||||
import org.jclouds.blobstore.domain.Blob;
|
||||
import org.jclouds.blobstore.integration.StubBlobStoreContextBuilder;
|
||||
import org.jclouds.demo.tweetstore.domain.StoredTweetStatus;
|
||||
import org.jclouds.demo.tweetstore.functions.ServiceToStoredTweetStatuses;
|
||||
import org.jclouds.demo.tweetstore.reference.TweetStoreConstants;
|
||||
|
@ -49,7 +49,7 @@ public class AddTweetsControllerTest {
|
|||
ExecutionException {
|
||||
Map<String, BlobStoreContext> services = Maps.newHashMap();
|
||||
for (String name : new String[] { "1", "2" }) {
|
||||
BlobStoreContext context = new StubBlobStoreContextBuilder().buildBlobStoreContext();
|
||||
BlobStoreContext context = new TransientBlobStoreContextBuilder().buildBlobStoreContext();
|
||||
context.getAsyncBlobStore().createContainerInLocation(null, container).get();
|
||||
Blob blob = context.getAsyncBlobStore().newBlob("1");
|
||||
blob.getMetadata().getUserMetadata().put(TweetStoreConstants.SENDER_NAME, "frank");
|
||||
|
|
|
@ -30,8 +30,8 @@ import java.util.concurrent.ExecutionException;
|
|||
|
||||
import org.jclouds.blobstore.BlobMap;
|
||||
import org.jclouds.blobstore.BlobStoreContext;
|
||||
import org.jclouds.blobstore.TransientBlobStoreContextBuilder;
|
||||
import org.jclouds.blobstore.domain.Blob;
|
||||
import org.jclouds.blobstore.integration.StubBlobStoreContextBuilder;
|
||||
import org.jclouds.demo.tweetstore.reference.TweetStoreConstants;
|
||||
import org.jclouds.twitter.TwitterClient;
|
||||
import org.jclouds.twitter.domain.Status;
|
||||
|
@ -56,8 +56,8 @@ public class StoreTweetsControllerTest {
|
|||
|
||||
Map<String, BlobStoreContext> createBlobStores() throws InterruptedException, ExecutionException {
|
||||
Map<String, BlobStoreContext> contexts = ImmutableMap.<String, BlobStoreContext> of("test1",
|
||||
new StubBlobStoreContextBuilder().buildBlobStoreContext(), "test2",
|
||||
new StubBlobStoreContextBuilder().buildBlobStoreContext());
|
||||
new TransientBlobStoreContextBuilder().buildBlobStoreContext(), "test2",
|
||||
new TransientBlobStoreContextBuilder().buildBlobStoreContext());
|
||||
for (BlobStoreContext blobstore : contexts.values()) {
|
||||
blobstore.getAsyncBlobStore().createContainerInLocation(null, "favo").get();
|
||||
}
|
||||
|
|
|
@ -25,8 +25,8 @@ import java.util.concurrent.ExecutionException;
|
|||
|
||||
import org.jclouds.blobstore.BlobMap;
|
||||
import org.jclouds.blobstore.BlobStoreContext;
|
||||
import org.jclouds.blobstore.TransientBlobStoreContextBuilder;
|
||||
import org.jclouds.blobstore.domain.Blob;
|
||||
import org.jclouds.blobstore.integration.StubBlobStoreContextBuilder;
|
||||
import org.jclouds.demo.tweetstore.domain.StoredTweetStatus;
|
||||
import org.jclouds.demo.tweetstore.reference.TweetStoreConstants;
|
||||
import org.testng.annotations.Test;
|
||||
|
@ -40,7 +40,7 @@ import org.testng.annotations.Test;
|
|||
public class KeyToStoredTweetStatusTest {
|
||||
|
||||
BlobMap createMap() throws InterruptedException, ExecutionException {
|
||||
BlobStoreContext context = new StubBlobStoreContextBuilder().buildBlobStoreContext();
|
||||
BlobStoreContext context = new TransientBlobStoreContextBuilder().buildBlobStoreContext();
|
||||
context.getBlobStore().createContainerInLocation(null, "test1");
|
||||
return context.createBlobMap("test1");
|
||||
}
|
||||
|
|
|
@ -25,8 +25,8 @@ import java.util.Map;
|
|||
import java.util.concurrent.ExecutionException;
|
||||
|
||||
import org.jclouds.blobstore.BlobStoreContext;
|
||||
import org.jclouds.blobstore.TransientBlobStoreContextBuilder;
|
||||
import org.jclouds.blobstore.domain.Blob;
|
||||
import org.jclouds.blobstore.integration.StubBlobStoreContextBuilder;
|
||||
import org.jclouds.demo.tweetstore.domain.StoredTweetStatus;
|
||||
import org.jclouds.demo.tweetstore.reference.TweetStoreConstants;
|
||||
import org.testng.annotations.Test;
|
||||
|
@ -46,7 +46,7 @@ public class ServiceToStoredTweetStatusesTest {
|
|||
ExecutionException {
|
||||
Map<String, BlobStoreContext> services = Maps.newHashMap();
|
||||
for (String name : new String[] { "1", "2" }) {
|
||||
BlobStoreContext context = new StubBlobStoreContextBuilder().buildBlobStoreContext();
|
||||
BlobStoreContext context = new TransientBlobStoreContextBuilder().buildBlobStoreContext();
|
||||
context.getAsyncBlobStore().createContainerInLocation(null, container).get();
|
||||
Blob blob = context.getAsyncBlobStore().newBlob("1");
|
||||
blob.getMetadata().getUserMetadata().put(TweetStoreConstants.SENDER_NAME, "frank");
|
||||
|
|
Loading…
Reference in New Issue