diff --git a/CHANGES.rst b/CHANGES.rst index 8367775..6e2e77f 100644 --- a/CHANGES.rst +++ b/CHANGES.rst @@ -7,7 +7,10 @@ Changelog * Restore warning about files included in the sdist but not added to the version control system (`issue #27 - `__), + `__). + +* Fix ``check-manifest relative/pathname`` (`issue #28 + `__). 0.19 (2014-02-09) diff --git a/check_manifest.py b/check_manifest.py index a701d09..218a0ee 100755 --- a/check_manifest.py +++ b/check_manifest.py @@ -577,7 +577,7 @@ def check_manifest(source_tree='.', create=False, update=False, """ all_ok = True with cd(source_tree): - if not is_package(source_tree): + if not is_package(): raise Failure('This is not a Python project (no setup.py).') read_config() read_manifest() diff --git a/tests.py b/tests.py index 59ad6a8..e1dc371 100644 --- a/tests.py +++ b/tests.py @@ -979,6 +979,14 @@ def test_all_is_well(self): self._create_repo_with_code() self.assertTrue(check_manifest()) + def test_relative_pathname(self): + from check_manifest import check_manifest + os.mkdir('subdir') + os.chdir('subdir') + self._create_repo_with_code() + os.chdir(os.pardir) + self.assertTrue(check_manifest('subdir')) + def test_suggestions(self): from check_manifest import check_manifest self._create_repo_with_code()