mirror of
https://github.com/pre-commit/pre-commit.git
synced 2026-02-17 08:14:42 +04:00
Remove legacy 'hooks.yaml' file support
This commit is contained in:
parent
7aeb4fe0f7
commit
86d9ca053b
8 changed files with 3 additions and 76 deletions
|
|
@ -60,23 +60,6 @@ def test_hooks(manifest):
|
|||
}
|
||||
|
||||
|
||||
def test_legacy_manifest_warn(store, tempdir_factory, log_warning_mock):
|
||||
path = make_repo(tempdir_factory, 'legacy_hooks_yaml_repo')
|
||||
head_sha = get_head_sha(path)
|
||||
repo_path = store.clone(path, head_sha)
|
||||
Manifest(repo_path, path).manifest_contents
|
||||
|
||||
# Should have printed a warning
|
||||
assert log_warning_mock.call_args_list[0][0][0] == (
|
||||
'{} uses legacy hooks.yaml to provide hooks.\n'
|
||||
'In newer versions, this file is called .pre-commit-hooks.yaml\n'
|
||||
'This will work in this version of pre-commit but will be removed at '
|
||||
'a later time.\n'
|
||||
'If `pre-commit autoupdate` does not silence this warning consider '
|
||||
'making an issue / pull request.'.format(path)
|
||||
)
|
||||
|
||||
|
||||
def test_default_python_language_version(store, tempdir_factory):
|
||||
path = make_repo(tempdir_factory, 'python_hooks_repo')
|
||||
repo_path = store.clone(path, get_head_sha(path))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue