Skip to content

Commit

Permalink
should include 3.10 actually
Browse files Browse the repository at this point in the history
  • Loading branch information
c4ffein committed Aug 23, 2024
1 parent 8acb9de commit ab98221
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions tests/test_pagination.py
Original file line number Diff line number Diff line change
Expand Up @@ -428,11 +428,11 @@ def invalid2(request):
pass


@pytest.mark.skipif(version_info < (3, 11), reason="Not needed at this Python version")
@pytest.mark.skipif(version_info < (3, 10), reason="Not needed at this Python version")
def test_pagination_works_with_unnamed_classes():
"""
This test lets you check that the typing.Any case handled in `ninja.pagination.make_response_paginated`
works for Python>=3.11, as a typing.Any does possess the __name__ atribute past that version
works for Python>=3.10, as a typing.Any does possess the __name__ atribute past that version
"""
operation = Operation("/whatever", ["GET"], lambda: None, response=List[int])
operation.response_models[200].__annotations__["response"] = List[object()]
Expand Down

0 comments on commit ab98221

Please sign in to comment.