mirror of
https://github.com/pre-commit/pre-commit.git
synced 2026-02-17 00:04:42 +04:00
remove deprecated python_venv alias
This commit is contained in:
parent
a2f7b80e89
commit
801b956304
4 changed files with 0 additions and 36 deletions
|
|
@ -1,7 +0,0 @@
|
|||
from __future__ import annotations
|
||||
|
||||
from pre_commit.all_languages import languages
|
||||
|
||||
|
||||
def test_python_venv_is_an_alias_to_python():
|
||||
assert languages['python_venv'] is languages['python']
|
||||
|
|
@ -80,24 +80,6 @@ def _test_hook_repo(
|
|||
assert out == expected
|
||||
|
||||
|
||||
def test_python_venv_deprecation(store, caplog):
|
||||
config = {
|
||||
'repo': 'local',
|
||||
'hooks': [{
|
||||
'id': 'example',
|
||||
'name': 'example',
|
||||
'language': 'python_venv',
|
||||
'entry': 'echo hi',
|
||||
}],
|
||||
}
|
||||
_get_hook(config, store, 'example')
|
||||
assert caplog.messages[-1] == (
|
||||
'`repo: local` uses deprecated `language: python_venv`. '
|
||||
'This is an alias for `language: python`. '
|
||||
'Often `pre-commit autoupdate --repo local` will fix this.'
|
||||
)
|
||||
|
||||
|
||||
def test_system_hook_with_spaces(tempdir_factory, store):
|
||||
_test_hook_repo(
|
||||
tempdir_factory, store, 'system_hook_with_spaces_repo',
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue