Fix services to work better with other regions. Closes #17.
This commit is contained in:
parent
d96769a91c
commit
8fe0c91853
@ -1,7 +1,7 @@
|
|||||||
from .responses import handler
|
from .responses import handler
|
||||||
|
|
||||||
url_bases = [
|
url_bases = [
|
||||||
"https?://dynamodb.us-east-1.amazonaws.com",
|
"https?://dynamodb.(.+).amazonaws.com",
|
||||||
"https?://sts.amazonaws.com",
|
"https?://sts.amazonaws.com",
|
||||||
]
|
]
|
||||||
|
|
||||||
|
@ -2,7 +2,7 @@ from .responses import EC2Response
|
|||||||
|
|
||||||
|
|
||||||
url_bases = [
|
url_bases = [
|
||||||
"https?://ec2.us-east-1.amazonaws.com",
|
"https?://ec2.(.+).amazonaws.com",
|
||||||
]
|
]
|
||||||
|
|
||||||
url_paths = {
|
url_paths = {
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
from .responses import EmailResponse
|
from .responses import EmailResponse
|
||||||
|
|
||||||
url_bases = [
|
url_bases = [
|
||||||
"https?://email.us-east-1.amazonaws.com"
|
"https?://email.(.+).amazonaws.com"
|
||||||
]
|
]
|
||||||
|
|
||||||
url_paths = {
|
url_paths = {
|
||||||
|
@ -43,3 +43,12 @@ def test_sts_handler():
|
|||||||
res = requests.post("https://sts.amazonaws.com/", data={"GetSessionToken": ""})
|
res = requests.post("https://sts.amazonaws.com/", data={"GetSessionToken": ""})
|
||||||
res.ok.should.be.ok
|
res.ok.should.be.ok
|
||||||
res.text.should.contain("SecretAccessKey")
|
res.text.should.contain("SecretAccessKey")
|
||||||
|
|
||||||
|
|
||||||
|
@mock_dynamodb
|
||||||
|
def test_dynamodb_with_connect_to_region():
|
||||||
|
# this will work if connected with boto.connect_dynamodb()
|
||||||
|
dynamodb = boto.dynamodb.connect_to_region('us-west-2')
|
||||||
|
|
||||||
|
schema = dynamodb.create_schema('column1', str(), 'column2', int())
|
||||||
|
dynamodb.create_table('table1', schema, 200, 200)
|
||||||
|
Loading…
x
Reference in New Issue
Block a user