mirror of
https://github.com/pre-commit/pre-commit.git
synced 2026-02-17 08:14:42 +04:00
remove docker_is_running check from source
Moved to testing.util so it can be used for the skipif_cant_run_docker test hooks.
This commit is contained in:
parent
f1de792877
commit
eb8b48aeb4
4 changed files with 11 additions and 31 deletions
|
|
@ -1,15 +1,6 @@
|
|||
from unittest import mock
|
||||
|
||||
from pre_commit.languages import docker
|
||||
from pre_commit.util import CalledProcessError
|
||||
|
||||
|
||||
def test_docker_is_running_process_error():
|
||||
with mock.patch(
|
||||
'pre_commit.languages.docker.cmd_output_b',
|
||||
side_effect=CalledProcessError(1, (), 0, b'', None),
|
||||
):
|
||||
assert docker.docker_is_running() is False
|
||||
|
||||
|
||||
def test_docker_fallback_user():
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue