mirror of
https://github.com/pre-commit/pre-commit.git
synced 2026-02-17 08:14:42 +04:00
Fix missing create=True attribute in docker tests
This commit is contained in:
parent
b43b6a61ab
commit
a21a4f46c7
1 changed files with 2 additions and 2 deletions
|
|
@ -18,12 +18,12 @@ def test_docker_is_running_process_error():
|
|||
def test_docker_fallback_uid():
|
||||
def invalid_attribute():
|
||||
raise AttributeError
|
||||
with mock.patch('os.getuid', invalid_attribute):
|
||||
with mock.patch('os.getuid', invalid_attribute, create=True):
|
||||
assert docker.getuid() == docker.FALLBACK_UID
|
||||
|
||||
|
||||
def test_docker_fallback_gid():
|
||||
def invalid_attribute():
|
||||
raise AttributeError
|
||||
with mock.patch('os.getgid', invalid_attribute):
|
||||
with mock.patch('os.getgid', invalid_attribute, create=True):
|
||||
assert docker.getgid() == docker.FALLBACK_GID
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue