Only test passthrough exception in non-server mode.
This commit is contained in:
parent
c7147b06b1
commit
11506e21d5
1 changed files with 7 additions and 6 deletions
|
|
@ -2,7 +2,7 @@ import requests
|
||||||
import sure # noqa
|
import sure # noqa
|
||||||
|
|
||||||
import boto3
|
import boto3
|
||||||
from moto import mock_sqs
|
from moto import mock_sqs, settings
|
||||||
|
|
||||||
|
|
||||||
@mock_sqs
|
@mock_sqs
|
||||||
|
|
@ -14,8 +14,9 @@ def test_passthrough_requests():
|
||||||
assert res.status_code == 200
|
assert res.status_code == 200
|
||||||
|
|
||||||
|
|
||||||
@mock_sqs
|
if settings.TEST_SERVER_MODE:
|
||||||
def test_requests_to_amazon_subdomains_dont_work():
|
@mock_sqs
|
||||||
res = requests.get("https://fakeservice.amazonaws.com/foo/bar")
|
def test_requests_to_amazon_subdomains_dont_work():
|
||||||
assert res.content == b"The method is not implemented"
|
res = requests.get("https://fakeservice.amazonaws.com/foo/bar")
|
||||||
assert res.status_code == 400
|
assert res.content == b"The method is not implemented"
|
||||||
|
assert res.status_code == 400
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue