Skip to content

Commit

Permalink
Construct the union in stages for Python 3.10
Browse files Browse the repository at this point in the history
  • Loading branch information
DavidCEllis committed Dec 5, 2024
1 parent b9c8277 commit 5dcb521
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions tests/test_sql_classes.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,11 @@

def test_type_map():
# Check that the MAPPED_TYPES matches the union of types in TYPE_MAP
mapped_type_construct = typing.Union[*TYPE_MAP.keys()]
assert MAPPED_TYPES == mapped_type_construct
union = None
for t in TYPE_MAP.keys():
union = typing.Union[union, t]

assert MAPPED_TYPES == union


class TestListFlattenSeparate:
Expand Down

0 comments on commit 5dcb521

Please sign in to comment.