Add make archives scripts.

This commit is contained in:
Anthony Sottile 2014-06-23 12:57:55 -07:00
parent d02f41920f
commit a7133d6742
4 changed files with 158 additions and 0 deletions

View file

@ -12,6 +12,7 @@ from pre_commit.util import clean_path_on_failure
from pre_commit.util import entry
from pre_commit.util import memoize_by_cwd
from pre_commit.util import shell_escape
from pre_commit.util import tmpdir
@pytest.fixture
@ -112,3 +113,9 @@ def test_clean_path_on_failure_cleans_for_system_exit(in_tmpdir):
)
def test_shell_escape(input_str, expected):
assert shell_escape(input_str) == expected
def test_tmpdir():
with tmpdir() as tempdir:
assert os.path.exists(tempdir)
assert not os.path.exists(tempdir)