Use set rather than list for commit message related stages, remove

default file open modes, tidy up bash call for failing hook test
This commit is contained in:
Marc Jay 2019-04-21 21:58:01 +01:00
parent 64467f6ab9
commit 82969e4ba3
4 changed files with 5 additions and 5 deletions

View file

@ -678,7 +678,7 @@ def test_prepare_commit_msg_integration_passing(
commit_msg_path = os.path.join(
prepare_commit_msg_repo, '.git/COMMIT_EDITMSG',
)
with io.open(commit_msg_path, 'rt') as f:
with io.open(commit_msg_path) as f:
assert 'Signed off by: ' in f.read()
@ -709,7 +709,7 @@ def test_prepare_commit_msg_legacy(
commit_msg_path = os.path.join(
prepare_commit_msg_repo, '.git/COMMIT_EDITMSG',
)
with io.open(commit_msg_path, 'rt') as f:
with io.open(commit_msg_path) as f:
assert 'Signed off by: ' in f.read()

View file

@ -615,7 +615,7 @@ def test_prepare_commit_msg_hook(cap_out, store, prepare_commit_msg_repo):
stage=False,
)
with io.open(filename, 'rt') as f:
with io.open(filename) as f:
assert 'Signed off by: ' in f.read()