MCPcopy Create free account
hub / github.com/msgspec/msgspec / test_generic_sub3

Method test_generic_sub3

tests/unit/test_utils.py:104–109  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

102 assert get_class_annotations(Sub[int]) == {"x": T, "y": List[int]}
103
104 def test_generic_sub3(self):
105 class Sub(Base[int], Generic[T]):
106 y: List[T]
107
108 assert get_class_annotations(Sub) == {"x": int, "y": List[T]}
109 assert get_class_annotations(Sub[float]) == {"x": int, "y": List[float]}
110
111 def test_generic_sub4(self):
112 class Sub(Base[T]):

Callers

nothing calls this directly

Calls 1

get_class_annotationsFunction · 0.90

Tested by

no test coverage detected