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

Fix asserts for called once in Python 3.12 #16103

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

hroncok
Copy link
Contributor

@hroncok hroncok commented Jul 10, 2023

Description

This fixes:

    E               AttributeError: 'called_with' is not a valid assertion. Use a spec for the mock if 'called_with' is meant to be an attribute.

    FAILED tests/TestOAuth2.py::test_refreshAccessTokenSuccess - AttributeError: ...
    FAILED tests/TestOAuth2.py::test_refreshAccessTokenFailed - AttributeError: '...
    FAILED tests/API/TestAccount.py::test_errorLoginState - AttributeError: 'call...
    FAILED tests/Settings/TestCuraStackBuilder.py::test_createMachineWithUnknownDefinition

Unfortunately, some assertions failed when the invocation was fixed. Hecen a draft.

Type of change

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Printer definition file(s)
  • Translations

How Has This Been Tested?

  • I built the package in Fedora 39 with Python 3.12.0b3

Test Configuration:

  • Operating System: Fedora 39

Checklist:

    E               AttributeError: 'called_with' is not a valid assertion. Use a spec for the mock if 'called_with' is meant to be an attribute.

    FAILED tests/TestOAuth2.py::test_refreshAccessTokenSuccess - AttributeError: ...
    FAILED tests/TestOAuth2.py::test_refreshAccessTokenFailed - AttributeError: '...
    FAILED tests/API/TestAccount.py::test_errorLoginState - AttributeError: 'call...
    FAILED tests/Settings/TestCuraStackBuilder.py::test_createMachineWithUnknownDefinition
@github-actions github-actions bot added the PR: Community Contribution 👑 Community Contribution PR's label Jul 10, 2023
@casperlamboo casperlamboo added the PR: BooBoos 😇 Suggestions for Typos, like the NoMesh or there is a suggested refactor label Feb 16, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
PR: BooBoos 😇 Suggestions for Typos, like the NoMesh or there is a suggested refactor PR: Community Contribution 👑 Community Contribution PR's
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants