From 9c290a7dbd8711b66d63a0210e383cebf5f2aeca Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Sebasti=C3=A1n=20Ram=C3=ADrez?= Date: Wed, 10 Dec 2025 10:58:19 +0100 Subject: [PATCH] =?UTF-8?q?=E2=9C=85=20Tweak=20test=20for=20Python=203.8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- tests/test_arbitrary_types.py | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/tests/test_arbitrary_types.py b/tests/test_arbitrary_types.py index 8b8417bae..e5fa95ef2 100644 --- a/tests/test_arbitrary_types.py +++ b/tests/test_arbitrary_types.py @@ -1,9 +1,10 @@ -from typing import Annotated +from typing import List import pytest from fastapi import FastAPI from fastapi.testclient import TestClient from inline_snapshot import snapshot +from typing_extensions import Annotated from .utils import needs_pydanticv2 @@ -24,7 +25,7 @@ def get_client(): FakeNumpyArrayPydantic = Annotated[ FakeNumpyArray, - WithJsonSchema(TypeAdapter(list[float]).json_schema()), + WithJsonSchema(TypeAdapter(List[float]).json_schema()), PlainSerializer(lambda v: v.data), ] @@ -65,7 +66,7 @@ def test_typeadapter(): FakeNumpyArrayPydantic = Annotated[ FakeNumpyArray, - WithJsonSchema(TypeAdapter(list[float]).json_schema()), + WithJsonSchema(TypeAdapter(List[float]).json_schema()), PlainSerializer(lambda v: v.data), ]