Skip to content

Commit a644942

Browse files
[pre-commit.ci] auto fixes from pre-commit.com hooks
for more information, see https://pre-commit.ci
1 parent 9984eae commit a644942

File tree

1 file changed

+3
-2
lines changed

1 file changed

+3
-2
lines changed

tests/tests_fabric/utilities/test_data.py

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,8 +53,9 @@ def test_has_len():
5353
def test_replace_dunder_methods_multiple_loaders_without_init():
5454
"""In case of a class, that inherits from a class that we are patching, but doesn't define its own `__init__`
5555
method (the one we are wrapping), it can happen, that `hasattr(cls, "__old__init__")` is True because of parent
56-
class, but it is impossible to delete, because that method is owned by parent class. Furthermore, the error occurred
57-
only sometimes because it depends on the order in which we are iterating over a set of classes we are patching.
56+
class, but it is impossible to delete, because that method is owned by parent class. Furthermore, the error
57+
occurred only sometimes because it depends on the order in which we are iterating over a set of classes we are
58+
patching.
5859
5960
This test simulates the behavior by generating sufficient number of dummy classes, which do not define `__init__`
6061
and are children of `DataLoader`. We are testing that a) context manager `_replace_dunder_method` exits cleanly, and

0 commit comments

Comments
 (0)