Skip to content

Commit 66d7e71

Browse files
authored
Merge pull request #18 from nlesc-nano/devel2
Check for the presence of the _isdir rather than the OS type
2 parents f420cdd + 61e17d1 commit 66d7e71

File tree

4 files changed

+9
-3
lines changed

4 files changed

+9
-3
lines changed

CHANGELOG.rst

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,6 +6,12 @@ All notable changes to this project will be documented in this file.
66
This project adheres to `Semantic Versioning <http://semver.org/>`_.
77

88

9+
2.2.3
10+
*****
11+
* Windows bug fix: Check for the presence of the ``AssertionManager._isdir()``
12+
rather than the type of operating system.
13+
14+
915
2.2.2
1016
*****
1117
* Replaced `pycodestyle <https://pypi.org/project/pycodestyle/>`_ tests with

README.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@
1818

1919

2020
##################
21-
AssertionLib 2.2.2
21+
AssertionLib 2.2.3
2222
##################
2323

2424
A package for performing assertions and providing informative exception messages.

assertionlib/__version__.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
__version__ = '2.2.2'
1+
__version__ = '2.2.3'

assertionlib/manager.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -259,7 +259,7 @@ def __new__(mcls, name, bases, namespace) -> '_MetaAM': # noqa: N804
259259
cls.allclose = cls.isclose # type: ignore
260260

261261
# On windows os.path.isdir is an alias for the ._isdir function
262-
if os.name == 'nt':
262+
if hasattr(cls, '_isdir'):
263263
cls.isdir = cls._isdir # type: ignore
264264
cls.isdir.__name__ = 'isdir' # type: ignore
265265
cls.isdir.__qualname__ = 'isdir' # type: ignore

0 commit comments

Comments
 (0)