Port test suite from nose to pytest.

This just eliminates all errors on the tests collection. Elimination of
failures is left to the next commit.
This commit is contained in:
Matěj Cepl 2020-10-06 07:54:49 +02:00
commit 77dc60ea97
146 changed files with 1172 additions and 1277 deletions

View file

@ -4,7 +4,7 @@ import sure # noqa
import zipfile
from botocore.exceptions import ClientError
from moto import mock_cloudformation, mock_iam, mock_lambda, mock_s3, mock_sqs
from nose.tools import assert_raises
import pytest
from string import Template
from uuid import uuid4
@ -109,7 +109,7 @@ def test_lambda_can_be_deleted_by_cloudformation():
# Delete Stack
cf.delete_stack(StackName=stack["StackId"])
# Verify function was deleted
with assert_raises(ClientError) as e:
with pytest.raises(ClientError) as e:
lmbda.get_function(FunctionName=created_fn_name)
e.exception.response["Error"]["Code"].should.equal("ResourceNotFoundException")