# HG changeset patch # User Martin von Zweigbergk # Date 1576173543 28800 # Node ID 527eba3013ea43205892e49d6fb39e67e28d6f04 # Parent 1390bb81163e535eea3feab07a99122a70eba68b tests: make test-config-env.py a little less hacky Overriding os.path.isdir to always returns False is very confusing. Let's make it more explicit by specifically not returning any defaultrc/ configs. Differential Revision: https://phab.mercurial-scm.org/D7623 diff -r 1390bb81163e -r 527eba3013ea tests/test-config-env.py --- a/tests/test-config-env.py Thu Dec 12 12:57:13 2019 -0800 +++ b/tests/test-config-env.py Thu Dec 12 09:59:03 2019 -0800 @@ -6,6 +6,7 @@ from mercurial import ( encoding, + extensions, rcutil, ui as uimod, util, @@ -35,9 +36,10 @@ return [join(b'userrc')] +extensions.wrapfunction(rcutil, 'defaultrcpath', lambda orig: []) + rcutil.systemrcpath = systemrcpath rcutil.userrcpath = userrcpath -os.path.isdir = lambda x: False # hack: do not load default.d/*.rc # utility to print configs def printconfigs(env):