There was an error while loading. Please reload this page.
1 parent b43b6a6 commit a21a4f4Copy full SHA for a21a4f4
1 file changed
tests/languages/docker_test.py
@@ -18,12 +18,12 @@ def test_docker_is_running_process_error():
18
def test_docker_fallback_uid():
19
def invalid_attribute():
20
raise AttributeError
21
- with mock.patch('os.getuid', invalid_attribute):
+ with mock.patch('os.getuid', invalid_attribute, create=True):
22
assert docker.getuid() == docker.FALLBACK_UID
23
24
25
def test_docker_fallback_gid():
26
27
28
- with mock.patch('os.getgid', invalid_attribute):
+ with mock.patch('os.getgid', invalid_attribute, create=True):
29
assert docker.getgid() == docker.FALLBACK_GID
0 commit comments