Add test for exclusion expectation. Ref #1650.

This commit is contained in:
Jason R. Coombs 2019-12-31 12:47:46 -05:00
parent 589a70571a
commit f171cde150
1 changed files with 16 additions and 0 deletions

View File

@ -463,6 +463,22 @@ class TestSdistTest:
manifest = cmd.filelist.files
assert 'pyproject.toml' in manifest
def test_pyproject_toml_excluded(self):
"""
Check that pyproject.toml can excluded even if present
"""
open(os.path.join(self.temp_dir, 'pyproject.toml'), 'w').close()
with open('MANIFEST.in', 'w') as mts:
print('exclude pyproject.toml', file=mts)
dist = Distribution(SETUP_ATTRS)
dist.script_name = 'setup.py'
cmd = sdist(dist)
cmd.ensure_finalized()
with quiet():
cmd.run()
manifest = cmd.filelist.files
assert 'pyproject.toml' not in manifest
def test_default_revctrl():
"""