Skip to main content

pytest-aiomoto

Project description

pytest-aiomoto

Build Status Documentation Status

PyPI version Python versions

pytest fixtures for AWS services, with support for asyncio fixtures using aiobotocore

Warning

  • This package is work in progress, it is not recommended for production purposes. During the initial phases of this project, it is likely that some releases could introduce breaking changes in test fixtures. It's highly recommended pinning this dependency to patch releases during the 0.x.y releases.
  • This package could restrict available versions of aws libs, including: aiobotocore, botocore, boto3, and moto.
  • The fixtures in this package might not be optimized for concurrent testing. It is not known yet whether the fixtures are thread safe or adequately randomized to support parallel test suites.

Installation

You can install "pytest-aiomoto" via pip

$ pip install pytest-aiomoto

Usage

To list the available fixtures

$ pytest --fixtures

This project attempts to provide some common fixtures for commonly used services. As such, it is not a generic package for any services; the moto project provides that and this project builds on that. This project aims to create some useful fixtures that behave nearly the same way for both synchronous clients (botocore) and asynchronous clients (aiobotocore).

Contributing

Contributions are welcome, if you build similar common fixtures or build on the existing package fixtures. The details for bug fixes could be complicated, due to the dependencies on aiobotocore and moto.

Please review github collaboration practices. Once you clone your fork of the repository:

cd pytest-aiomoto
make init
make test

On OSX, use gmake from Homebrew to get GNU make > 4.x.

It's recommended that development use python 3.8, to avoid introducing any python code that might not be compatible with the minimum version of python supported. This is important in the context of the general evolution of asyncio in python.

Most development is done in a linux context (e.g. Ubuntu LTS). If some development tools or common practices are not working as expected on OSX or Windows, there is limited support for adapting to various development environments.

Tests are run with pytest, please ensure the percentage of coverage at least stays the same before you submit a pull request. The expectation for contributions might be a slow process, please do not anticipate any turn around on the order of days (unless you're already a core contributor). Using your own fork can be a faster way to evolve your fixtures for your use cases.

Release Versions

Install pipx and use it to install versionner.

pipx install versionner
ver --help

With pipx and versionner installed, it can be used to manage releases for any python library. See the documentation for ver for details on how to manage sem-ver library releases. See .versionner.rc file for details of the project configuration.

Issues

If you encounter any problems, please file an issue along with a detailed description.

License

Distributed under the terms of the Apache Software License 2.0, "pytest-aiomoto" is free and open source software.

Copyright 2019-2023 Darren Weber

Licensed under the Apache License, Version 2.0 (the "License");
you may not use this file except in compliance with the License.
You may obtain a copy of the License at

   http://www.apache.org/licenses/LICENSE-2.0

Unless required by applicable law or agreed to in writing, software
distributed under the License is distributed on an "AS IS" BASIS,
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
See the License for the specific language governing permissions and
limitations under the License.

Notices

Inspiration for this project comes from testing the aio-aws project, which uses the Apache 2 license.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pytest_aiomoto-0.7.1.tar.gz (27.2 kB view details)

Uploaded Source

Built Distribution

pytest_aiomoto-0.7.1-py3-none-any.whl (38.9 kB view details)

Uploaded Python 3

File details

Details for the file pytest_aiomoto-0.7.1.tar.gz.

File metadata

  • Download URL: pytest_aiomoto-0.7.1.tar.gz
  • Upload date:
  • Size: 27.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.5.1 CPython/3.11.4 Darwin/22.5.0

File hashes

Hashes for pytest_aiomoto-0.7.1.tar.gz
Algorithm Hash digest
SHA256 df6bf2f967e11da3968db85dd59530b9f45f7b6e5215f2f83b1b8c38bd72a53a
MD5 474bcd1e8e3af7b1da723d4b57e22716
BLAKE2b-256 85ed282bf22db2eb68e02aaeb663dc6d8f21838dc0206ed03c96267af86b687b

See more details on using hashes here.

File details

Details for the file pytest_aiomoto-0.7.1-py3-none-any.whl.

File metadata

  • Download URL: pytest_aiomoto-0.7.1-py3-none-any.whl
  • Upload date:
  • Size: 38.9 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: poetry/1.5.1 CPython/3.11.4 Darwin/22.5.0

File hashes

Hashes for pytest_aiomoto-0.7.1-py3-none-any.whl
Algorithm Hash digest
SHA256 e84c46be37c29c865189b4bd5dd98860db95af4a5a7f87d50695ecdd20f1e797
MD5 fe43a2eff0397bc91a6a95720b7fc537
BLAKE2b-256 a0d328c447439deb30cf49c07b51f04381f7dff4187643be5e124df41130190c

See more details on using hashes here.

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page