Skip to content

Instantly share code, notes, and snippets.

@avegaraju
Created February 21, 2019 22:32
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save avegaraju/8c050b7fafdd808e515be8355cc92c10 to your computer and use it in GitHub Desktop.
Save avegaraju/8c050b7fafdd808e515be8355cc92c10 to your computer and use it in GitHub Desktop.
public class MocksDataStore
{
public AwsDynamoDbDataStore Create()
{
AmazonDynamoDBClient client = CreateAmazonDynamoDbClientWithLocalDbInstance();
AwsDynamoDbDataStore awsDynamoDbDataStore = new AwsDynamoDbDataStore(client);
return awsDynamoDbDataStore;
}
private static AmazonDynamoDBClient CreateAmazonDynamoDbClientWithLocalDbInstance()
{
var config = new AmazonDynamoDBConfig
{
ServiceURL = "http://localhost:8000"
};
return new AmazonDynamoDBClient(config);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment