fix: coverage

Following https://github.com/samuelcolvin/pydantic/pull/3247 it seems that
this case is not triggered anymore.
We still keep it just in case
This commit is contained in:
PrettyWood
2021-12-09 09:55:45 +01:00
parent 15d0ae56c9
commit afcd15522e
+3 -1
View File
@@ -270,7 +270,9 @@ class PydanticModelTransformer:
# Basically, it is an edge case when dealing with complex import logic
# This is the same logic used in the dataclasses plugin
continue
if not isinstance(node, Var):
if not isinstance(node, Var): # pragma: no cover
# Don't know if this edge case still happens with the `is_valid_field` check above
# but better safe than sorry
continue
# x: ClassVar[int] is ignored by dataclasses.