diff options
Diffstat (limited to 'test/test_traversal.py')
-rw-r--r-- | test/test_traversal.py | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/test/test_traversal.py b/test/test_traversal.py index 9b2a27b..5d9fbe1 100644 --- a/test/test_traversal.py +++ b/test/test_traversal.py @@ -31,7 +31,7 @@ class TestTraversal: 'allow tuple path' assert traverse_obj(_TEST_DATA, ['str']) == 'str', \ 'allow list path' - assert traverse_obj(_TEST_DATA, (value for value in ("str",))) == 'str', \ + assert traverse_obj(_TEST_DATA, (value for value in ('str',))) == 'str', \ 'allow iterable path' assert traverse_obj(_TEST_DATA, 'str') == 'str', \ 'single items should be treated as a path' @@ -70,7 +70,7 @@ class TestTraversal: def test_traversal_set(self): # transformation/type, like `expected_type` - assert traverse_obj(_TEST_DATA, (..., {str.upper}, )) == ['STR'], \ + assert traverse_obj(_TEST_DATA, (..., {str.upper})) == ['STR'], \ 'Function in set should be a transformation' assert traverse_obj(_TEST_DATA, (..., {str})) == ['str'], \ 'Type in set should be a type filter' @@ -276,7 +276,7 @@ class TestTraversal: '`...` should result in string (same value) if `traverse_string`' assert traverse_obj(_TRAVERSE_STRING_DATA, ('str', slice(0, None, 2)), traverse_string=True) == 'sr', \ '`slice` should result in string if `traverse_string`' - assert traverse_obj(_TRAVERSE_STRING_DATA, ('str', lambda i, v: i or v == "s"), traverse_string=True) == 'str', \ + assert traverse_obj(_TRAVERSE_STRING_DATA, ('str', lambda i, v: i or v == 's'), traverse_string=True) == 'str', \ 'function should result in string if `traverse_string`' assert traverse_obj(_TRAVERSE_STRING_DATA, ('str', (0, 2)), traverse_string=True) == ['s', 'r'], \ 'branching should result in list if `traverse_string`' |