Skip to content

Commit

Permalink
Fix error when make lint in test_type_engine.py
Browse files Browse the repository at this point in the history
  • Loading branch information
400Ping committed Nov 15, 2024
1 parent 309d560 commit b35b026
Showing 1 changed file with 1 addition and 7 deletions.
8 changes: 1 addition & 7 deletions tests/flytekit/unit/core/test_type_engine.py
Original file line number Diff line number Diff line change
Expand Up @@ -3624,12 +3624,6 @@ def test_structured_dataset_mismatch():
with pytest.raises(TypeTransformerFailedError):
TypeEngine.to_literal(FlyteContext.current_context(), df, StructuredDataset, TypeEngine.to_literal_type(StructuredDataset))

try:
from typing import Union
union_type = Union[int, str]
except TypeError:
union_type = int | str # For Python 3.10+

@pytest.mark.skip(reason="assert_type method not found in TypeEngine")
def test_assert_type_with_optional():
engine = TypeEngine()
Expand All @@ -3641,7 +3635,7 @@ def test_assert_type_with_optional():
def test_assert_type_with_union():
engine = TypeEngine()
value = "test"
expected_type = union_type
expected_type = int | str if sys.version_info >= (3, 10) else Union[int, str]
engine.assert_type(expected_type, value)

@pytest.mark.skip(reason="_fix_dataclass_int method not found in TypeEngine")
Expand Down

0 comments on commit b35b026

Please sign in to comment.