Skip to content

Instantly share code, notes, and snippets.

@ElvisLives
Created October 8, 2012 15:42
Show Gist options
  • Save ElvisLives/3853175 to your computer and use it in GitHub Desktop.
Save ElvisLives/3853175 to your computer and use it in GitHub Desktop.
Figuring Out Azure Contrib
using System;
using AzureContrib.WindowsAzure.StorageClient;
using Microsoft.WindowsAzure;
using Microsoft.WindowsAzure.StorageClient;
using Xunit;
namespace Tests.Azure
{
public class AzureIntegrationTests
{
[Fact]
public void Figure_Out_How_To_Use_Azure_Contrib()
{
ICloudStorageAccountManager cloudStorageAccountManager = new CloudStorageAccountManager(null,null);
cloudStorageAccountManager.AddCloudStorageAccount("teststorage", CloudConfigurationManager.GetSetting("AzureStorage"));
ICloudBlobClient cloudBlobClient = cloudStorageAccountManager.GetCloudBlobClient("teststorage");
Assert.NotNull(cloudBlobClient);
CloudBlob blobReference = cloudBlobClient.GetBlobReference("testing/defaultStoreSize.jpg");
blobReference.DownloadToFile("test.jpg");
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment