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:
Ruairidh MacLeod 2020-08-23 00:14:10 +00:00 committed by Anthony Sottile
parent f1de792877
commit eb8b48aeb4
4 changed files with 11 additions and 31 deletions

View file

@ -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():