From 7b1f2a06d24bd90a28405e52e9184848d33576c7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Andr=C3=A9s=20Delfino?= <34587441+andresdelfino@users.noreply.github.com> Date: Mon, 23 Apr 2018 12:51:43 -0300 Subject: [PATCH] Add test for PR #5293 (#5325) * Test that trailing os.sep are ignored while searching PATH * Simplify paths list creation --- news/5325.bugfix | 1 + tests/unit/test_wheel.py | 7 +++++++ 2 files changed, 8 insertions(+) create mode 100644 news/5325.bugfix diff --git a/news/5325.bugfix b/news/5325.bugfix new file mode 100644 index 000000000..0d79eb054 --- /dev/null +++ b/news/5325.bugfix @@ -0,0 +1 @@ +Add test for PR 5293: Remove trailing os.sep to avoid false negatives diff --git a/tests/unit/test_wheel.py b/tests/unit/test_wheel.py index 9b029eedb..6d3c1c7a7 100644 --- a/tests/unit/test_wheel.py +++ b/tests/unit/test_wheel.py @@ -463,3 +463,10 @@ class TestMessageAboutScriptsNotOnPATH(object): assert retval is None else: assert retval is not None + + def test_trailing_ossep_removal(self): + retval = self._template( + paths=[os.path.join('a', 'b', '')], + scripts=[os.path.join('a', 'b', 'c')] + ) + assert retval is None -- GitLab