Closed a-detiste closed 1 month ago
Hi,
The baseline is not explicitly documented.
So yes a plain "from unittest import mock" would be enough in modern system.
Le lun. 10 juin 2024 à 15:02, Andrey Lebedev @.***> a écrit :
@.**** commented on this pull request.
In src/ofxstatement/tests/test_plugin.py https://github.com/kedder/ofxstatement/pull/297#discussion_r1633213484:
@@ -1,6 +1,9 @@ import unittest
-import mock +try:
- from unittest import mock +except ImportError:
- import mock
We don't support the ancient versions of Python, so I think this precaution is unnecessary (unless I'm missing something).
— Reply to this email directly, view it on GitHub https://github.com/kedder/ofxstatement/pull/297#pullrequestreview-2107737864, or unsubscribe https://github.com/notifications/unsubscribe-auth/AB47WUELUZ2U5HZ6ABFNIWDZGWPX7AVCNFSM6AAAAABJBG5GSWVHI2DSMVQWIX3LMV43YUDVNRWFEZLROVSXG5CSMV3GSZLXHMZDCMBXG4ZTOOBWGQ . You are receiving this because you authored the thread.Message ID: @.***>
It is somewhat documented in pyproject.toml: https://github.com/kedder/ofxstatement/blob/225075416c6a4f4bd9a1dd8b802e81f88dafb40e/pyproject.toml#L13
I think we can assume it is not running on earlier pythons (and it probably won't for a lot of other reasons)
Good catch. I didn't noticed.
3.9 is plenty enough.
"mock" is fully fossilizied since 3.6
Le lun. 10 juin 2024 à 15:13, Andrey Lebedev @.***> a écrit :
It is somewhat documented in pyproject.toml: https://github.com/kedder/ofxstatement/blob/225075416c6a4f4bd9a1dd8b802e81f88dafb40e/pyproject.toml#L13
I think we can assume it is not running on earlier pythons (and it probably won't for a lot of other reasons)
— Reply to this email directly, view it on GitHub, or unsubscribe. You are receiving this because you authored the thread.Message ID: @.***>
Thank you!
https://github.com/testing-cabal/mock
mock is now part of the Python standard library, available as unittest.mock in Python 3.3 onwards.