mirror of
https://github.com/pre-commit/pre-commit.git
synced 2026-04-15 01:51:46 +04:00
upgrade hooks, pyupgrade pre-commit
This commit is contained in:
parent
764c765d29
commit
30c1e8289f
91 changed files with 176 additions and 437 deletions
|
|
@ -1,6 +1,3 @@
|
|||
from __future__ import absolute_import
|
||||
from __future__ import unicode_literals
|
||||
|
||||
import argparse
|
||||
import os.path
|
||||
|
||||
|
|
@ -27,7 +24,7 @@ def test_append_replace_default(argv, expected):
|
|||
assert parser.parse_args(argv).f == expected
|
||||
|
||||
|
||||
class Args(object):
|
||||
class Args:
|
||||
def __init__(self, **kwargs):
|
||||
kwargs.setdefault('command', 'help')
|
||||
kwargs.setdefault('config', C.CONFIG_FILE)
|
||||
|
|
@ -189,4 +186,4 @@ def test_expected_fatal_error_no_git_repo(in_tmpdir, cap_out, mock_store_dir):
|
|||
'An error has occurred: FatalError: git failed. '
|
||||
'Is it installed, and are you in a Git repository directory?'
|
||||
)
|
||||
assert cap_out_lines[-1] == 'Check the log at {}'.format(log_file)
|
||||
assert cap_out_lines[-1] == f'Check the log at {log_file}'
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue