2022-04-15 01:41:22 +00:00
|
|
|
{ lib
|
|
|
|
, buildPythonPackage
|
|
|
|
, fetchPypi
|
|
|
|
, pythonOlder
|
|
|
|
|
|
|
|
# runtime
|
2020-04-24 23:36:52 +00:00
|
|
|
, aws-xray-sdk
|
|
|
|
, boto3
|
|
|
|
, botocore
|
|
|
|
, cfn-lint
|
2022-04-15 01:41:22 +00:00
|
|
|
, cryptography
|
2020-04-24 23:36:52 +00:00
|
|
|
, docker
|
|
|
|
, flask
|
2022-02-10 20:34:41 +00:00
|
|
|
, flask-cors
|
2022-04-15 01:41:22 +00:00
|
|
|
, graphql-core
|
|
|
|
, idna
|
2020-04-24 23:36:52 +00:00
|
|
|
, jinja2
|
|
|
|
, jsondiff
|
2022-04-15 01:41:22 +00:00
|
|
|
, python-dateutil
|
2020-04-24 23:36:52 +00:00
|
|
|
, python-jose
|
|
|
|
, pytz
|
2022-04-15 01:41:22 +00:00
|
|
|
, pyyaml
|
2020-04-24 23:36:52 +00:00
|
|
|
, requests
|
|
|
|
, responses
|
|
|
|
, sshpubkeys
|
|
|
|
, werkzeug
|
|
|
|
, xmltodict
|
2022-04-15 01:41:22 +00:00
|
|
|
|
|
|
|
# tests
|
|
|
|
, freezegun
|
2021-02-16 17:04:54 +00:00
|
|
|
, pytestCheckHook
|
2022-02-10 20:34:41 +00:00
|
|
|
, pytest-xdist
|
2022-04-15 01:41:22 +00:00
|
|
|
, sure
|
2020-04-24 23:36:52 +00:00
|
|
|
}:
|
|
|
|
|
|
|
|
buildPythonPackage rec {
|
|
|
|
pname = "moto";
|
2022-04-15 01:41:22 +00:00
|
|
|
version = "3.0.5";
|
|
|
|
format = "setuptools";
|
|
|
|
|
|
|
|
disabled = pythonOlder "3.6";
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
src = fetchPypi {
|
|
|
|
inherit pname version;
|
2022-04-15 01:41:22 +00:00
|
|
|
sha256 = "sha256-hfLs4K0DBaoTo5E5zmSKs6/hwEyzKsHbjV5ekRfU0Q4=";
|
2020-04-24 23:36:52 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
propagatedBuildInputs = [
|
|
|
|
aws-xray-sdk
|
|
|
|
boto3
|
|
|
|
botocore
|
|
|
|
cfn-lint
|
2022-04-15 01:41:22 +00:00
|
|
|
cryptography
|
2020-04-24 23:36:52 +00:00
|
|
|
docker
|
2022-04-15 01:41:22 +00:00
|
|
|
flask
|
|
|
|
flask-cors
|
|
|
|
graphql-core
|
|
|
|
idna
|
2020-04-24 23:36:52 +00:00
|
|
|
jinja2
|
|
|
|
jsondiff
|
2022-04-15 01:41:22 +00:00
|
|
|
python-dateutil
|
2020-04-24 23:36:52 +00:00
|
|
|
python-jose
|
|
|
|
pytz
|
2022-04-15 01:41:22 +00:00
|
|
|
pyyaml
|
2020-04-24 23:36:52 +00:00
|
|
|
requests
|
|
|
|
responses
|
|
|
|
sshpubkeys
|
|
|
|
werkzeug
|
|
|
|
xmltodict
|
2022-04-15 01:41:22 +00:00
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2022-02-10 20:34:41 +00:00
|
|
|
checkInputs = [
|
|
|
|
freezegun
|
|
|
|
pytest-xdist
|
2022-04-15 01:41:22 +00:00
|
|
|
pytestCheckHook
|
2022-02-10 20:34:41 +00:00
|
|
|
sure
|
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-02-16 17:04:54 +00:00
|
|
|
pytestFlagsArray = [
|
2022-04-15 01:41:22 +00:00
|
|
|
"--numprocesses $NIX_BUILD_CORES"
|
|
|
|
|
|
|
|
# Disable tests that try to access the network
|
|
|
|
"--deselect=tests/test_cloudformation/test_cloudformation_custom_resources.py::test_create_custom_lambda_resource__verify_cfnresponse_failed"
|
|
|
|
"--deselect=tests/test_cloudformation/test_server.py::test_cloudformation_server_get"
|
|
|
|
"--deselect=tests/test_core/test_decorator_calls.py::test_context_manager"
|
|
|
|
"--deselect=tests/test_core/test_decorator_calls.py::test_decorator_start_and_stop"
|
|
|
|
"--deselect=tests/test_core/test_request_mocking.py::test_passthrough_requests"
|
|
|
|
"--deselect=tests/test_firehose/test_firehose_put.py::test_put_record_batch_http_destination"
|
|
|
|
"--deselect=tests/test_firehose/test_firehose_put.py::test_put_record_http_destination"
|
|
|
|
"--deselect=tests/test_logs/test_integration.py::test_put_subscription_filter_with_lambda"
|
|
|
|
"--deselect=tests/test_sqs/test_integration.py::test_invoke_function_from_sqs_exception"
|
|
|
|
"--deselect=tests/test_sqs/test_sqs_integration.py::test_invoke_function_from_sqs_exception"
|
|
|
|
"--deselect=tests/test_stepfunctions/test_stepfunctions.py::test_state_machine_creation_fails_with_invalid_names"
|
|
|
|
"--deselect=tests/test_stepfunctions/test_stepfunctions.py::test_state_machine_list_executions_with_pagination"
|
|
|
|
|
|
|
|
# json.decoder.JSONDecodeError: Expecting value: line 1 column 1 (char 0)
|
|
|
|
"--deselect=tests/test_cloudformation/test_cloudformation_stack_integration.py::test_lambda_function"
|
|
|
|
];
|
|
|
|
|
|
|
|
disabledTestPaths = [
|
|
|
|
# xml.parsers.expat.ExpatError: out of memory: line 1, column 0
|
|
|
|
"tests/test_sts/test_sts.py"
|
|
|
|
# botocore.exceptions.NoCredentialsError: Unable to locate credentials
|
|
|
|
"tests/test_redshiftdata/test_redshiftdata.py"
|
|
|
|
# Tries to access the network
|
|
|
|
"tests/test_appsync/test_appsync_schema.py"
|
|
|
|
"tests/test_awslambda/test_lambda_eventsourcemapping.py"
|
|
|
|
"tests/test_awslambda/test_lambda_invoke.py"
|
|
|
|
"tests/test_batch/test_batch_jobs.py"
|
2021-02-16 17:04:54 +00:00
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
2021-02-16 17:04:54 +00:00
|
|
|
disabledTests = [
|
2022-03-30 09:31:56 +00:00
|
|
|
# only appears in aarch64 currently, but best to be safe
|
|
|
|
"test_state_machine_list_executions_with_filter"
|
2021-02-16 17:04:54 +00:00
|
|
|
];
|
2020-04-24 23:36:52 +00:00
|
|
|
|
|
|
|
meta = with lib; {
|
|
|
|
description = "Allows your tests to easily mock out AWS Services";
|
|
|
|
homepage = "https://github.com/spulec/moto";
|
|
|
|
license = licenses.asl20;
|
|
|
|
maintainers = [ ];
|
|
|
|
};
|
|
|
|
}
|