Skip to content

Commit

Permalink
skip exc handler test if < 3.10
Browse files Browse the repository at this point in the history
Signed-off-by: Yee Hing Tong <[email protected]>
  • Loading branch information
wild-endeavor committed Nov 26, 2024
1 parent 30e0bba commit cbf3f12
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion tests/flytekit/unit/utils/test_asyn.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
import os
import threading
import sys

import mock
import pytest
Expand Down Expand Up @@ -126,10 +127,11 @@ def test_recursive_calling():
assert str(os.getpid()) in k


@pytest.mark.skipif(sys.version_info < (3, 10), reason="Requires Python 3.10 or higher")
@mock.patch("flytekit.utils.asyn._TaskRunner.get_exc_handler")
def test_error_two_ways(mock_getter):
# Test exception handling two ways
mock_handler =mock.MagicMock()
mock_handler = mock.MagicMock()
mock_getter.return_value = mock_handler

async def runner_1():
Expand Down

0 comments on commit cbf3f12

Please sign in to comment.