Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Pytest warning fix for contract test contract_update_without_create #971

Merged
merged 3 commits into from
Jan 26, 2023

Conversation

carpnick
Copy link
Contributor

Issue #, if available:

Description of changes:

Fix warning below when running Contract tests

Pytest warning when running contract tests:

resource/handler_update_invalid.py::contract_update_without_create
  /opt/homebrew/lib/python3.10/site-packages/_pytest/python.py:199: PytestReturnNotNoneWarning: Expected None, but resource/handler_update_invalid.py::contract_update_without_create returned <HandlerErrorCode.NotFound: 'NotFound'>, which will be an error in a future version of pytest.  Did you mean to use `assert` instead of `return`?
    warnings.warn(

-- Docs: https://docs.pytest.org/en/stable/how-to/capture-warnings.html

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.

@mmaeng
Copy link
Contributor

mmaeng commented Jan 25, 2023

Looks like there is a formatting/linting change that pre-commit wants to do. But LGTM with that update

@mmaeng mmaeng merged commit df37e64 into aws-cloudformation:master Jan 26, 2023
@carpnick carpnick deleted the feature/warningfix branch October 10, 2023 19:34
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants