Skip to content

Commit

Permalink
Add test case for -export-ignore.
Browse files Browse the repository at this point in the history
  • Loading branch information
Kentzo committed Aug 13, 2018
1 parent 6b7134d commit d32b1ca
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions test_git_archive_all.py
Original file line number Diff line number Diff line change
Expand Up @@ -169,6 +169,12 @@ def archive(self, path):
'__init__.py': FileRecord('#Although practicality beats purity.', excluded=True)
})

unset_export_ignore = deepcopy(base)
unset_export_ignore['.gitattributes'] = FileRecord('.* export-ignore\n*.htaccess -export-ignore', excluded=True)
unset_export_ignore['.a'] = FileRecord('Errors should never pass silently.', excluded=True)
unset_export_ignore['.b'] = FileRecord('Unless explicitly silenced.', excluded=True)
unset_export_ignore['.htaccess'] = FileRecord('In the face of ambiguity, refuse the temptation to guess.')


@pytest.mark.parametrize('contents', [
pytest.param(base, id='No Ignore'),
Expand All @@ -177,6 +183,7 @@ def archive(self, path):
pytest.param(ignore_in_nested_submodule, id='Ignore in Nested Submodule'),
pytest.param(ignore_in_submodule_from_root, id='Ignore in Submodule from Root'),
pytest.param(ignore_in_nested_submodule_from_root, id='Ignore in Nested Submodule from Root'),
pytest.param(unset_export_ignore, id='-export-ignore')
])
def test_ignore(contents, tmpdir, git_env):
"""
Expand Down

0 comments on commit d32b1ca

Please sign in to comment.