Security News
Research
Data Theft Repackaged: A Case Study in Malicious Wrapper Packages on npm
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
.. image:: https://img.shields.io/pypi/v/pytest-chalice.svg :target: https://pypi.org/project/pytest-chalice :alt: PyPI version
.. image:: https://img.shields.io/pypi/pyversions/pytest-chalice.svg :target: https://pypi.org/project/pytest-chalice :alt: Python versions
.. image:: https://travis-ci.org/studio3104/pytest-chalice.svg?branch=master :target: https://travis-ci.org/studio3104/pytest-chalice :alt: See Build Status on Travis CI
A set of py.test fixtures for AWS Chalice
pytest
_Chalice
_You can install "pytest-chalice" via pip
_ from PyPI
_::
$ pip install pytest-chalice
.. code-block:: python
from chalice import Chalice
app = Chalice(__name__)
@app.route('/')
def index:
return {'hello': 'world'}
pytest-chalice
expects a fixture called app
which will be the chalice app instance from your project. You can create it in your conftest.py
:
.. code-block:: python
import pytest
from chalice import Chalice
from project.app import app as chalice_app
@pytest.fixture
def app() -> Chalice:
return chalice_app
.. code-block:: python
from http import HTTPStatus
def test_index(client):
response = client.get('/')
assert response.status_code == HTTPStatus.OK
assert response.json == {'hello': 'world'}
See examples <https://github.com/studio3104/pytest-chalice/tree/master/examples>
_ for more detailed
Contributions are very welcome. Tests can be run with tox
_, please ensure
the coverage at least stays the same before you submit a pull request.
Distributed under the terms of the MIT
_ license, "pytest-chalice" is free and open source software
If you encounter any problems, please file an issue
_ along with a detailed description.
.. _@hackebrot
: https://github.com/hackebrot
.. _MIT
: http://opensource.org/licenses/MIT
.. _BSD-3
: http://opensource.org/licenses/BSD-3-Clause
.. _GNU GPL v3.0
: http://www.gnu.org/licenses/gpl-3.0.txt
.. _Apache Software License 2.0
: http://www.apache.org/licenses/LICENSE-2.0
.. _cookiecutter-pytest-plugin
: https://github.com/pytest-dev/cookiecutter-pytest-plugin
.. _file an issue
: https://github.com/studio3104/pytest-chalice/issues
.. _pytest
: https://github.com/pytest-dev/pytest
.. _tox
: https://tox.readthedocs.io/en/latest/
.. _pip
: https://pypi.org/project/pip/
.. _PyPI
: https://pypi.org/project
.. _Chalice
: https://github.com/aws/chalice
FAQs
A set of py.test fixtures for AWS Chalice
We found that pytest-chalice demonstrated a healthy version release cadence and project activity because the last version was released less than a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Security News
Research
The Socket Research Team breaks down a malicious wrapper package that uses obfuscation to harvest credentials and exfiltrate sensitive data.
Research
Security News
Attackers used a malicious npm package typosquatting a popular ESLint plugin to steal sensitive data, execute commands, and exploit developer systems.
Security News
The Ultralytics' PyPI Package was compromised four times in one weekend through GitHub Actions cache poisoning and failure to rotate previously compromised API tokens.