diff options
Diffstat (limited to 'Lib/unittest/mock.py')
-rw-r--r-- | Lib/unittest/mock.py | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/Lib/unittest/mock.py b/Lib/unittest/mock.py index 6b7f293..1a6c1a6 100644 --- a/Lib/unittest/mock.py +++ b/Lib/unittest/mock.py @@ -1713,6 +1713,7 @@ magic_methods = ( "complex int float index " "round trunc floor ceil " "bool next " + "fspath " ) numerics = ( @@ -1760,6 +1761,7 @@ _calculate_return_value = { '__hash__': lambda self: object.__hash__(self), '__str__': lambda self: object.__str__(self), '__sizeof__': lambda self: object.__sizeof__(self), + '__fspath__': lambda self: f"{type(self).__name__}/{self._extract_mock_name()}/{id(self)}", } _return_values = { |