Merge pull request #212 from pre-commit/no_gpg_moar

Don't gpg sign during test
This commit is contained in:
Anthony Sottile 2017-07-05 12:30:33 -07:00 committed by GitHub
commit a574f8cb2b
2 changed files with 8 additions and 9 deletions

View file

@ -81,12 +81,7 @@ def test_allows_gitlfs(temp_git_dir): # pragma: no cover
with temp_git_dir.as_cwd():
# Work around https://github.com/github/git-lfs/issues/913
cmd_output(
'git',
'commit',
'--no-gpg-sign',
'--allow-empty',
'-m',
'foo',
'git', 'commit', '--no-gpg-sign', '--allow-empty', '-m', 'foo',
)
cmd_output('git', 'lfs', 'install')
temp_git_dir.join('f.py').write('a' * 10000)

View file

@ -10,10 +10,14 @@ from pre_commit_hooks.forbid_new_submodules import main
def git_dir_with_git_dir(tmpdir):
with tmpdir.as_cwd():
cmd_output('git', 'init', '.')
cmd_output('git', 'commit', '-m', 'init', '--allow-empty')
cmd_output(
'git', 'commit', '-m', 'init', '--allow-empty', '--no-gpg-sign',
)
cmd_output('git', 'init', 'foo')
with tmpdir.join('foo').as_cwd():
cmd_output('git', 'commit', '-m', 'init', '--allow-empty')
cmd_output(
'git', 'commit', '-m', 'init', '--allow-empty', '--no-gpg-sign',
cwd=tmpdir.join('foo').strpath,
)
yield