D7623: tests: make test-config-env.py a little less hacky

martinvonz (Martin von Zweigbergk) phabricator at mercurial-scm.org
Sat Dec 14 22:11:13 EST 2019


Closed by commit rHG527eba3013ea: tests: make test-config-env.py a little less hacky (authored by martinvonz).
This revision was automatically updated to reflect the committed changes.

REPOSITORY
  rHG Mercurial

CHANGES SINCE LAST UPDATE
  https://phab.mercurial-scm.org/D7623?vs=18653&id=18732

CHANGES SINCE LAST ACTION
  https://phab.mercurial-scm.org/D7623/new/

REVISION DETAIL
  https://phab.mercurial-scm.org/D7623

AFFECTED FILES
  tests/test-config-env.py

CHANGE DETAILS

diff --git a/tests/test-config-env.py b/tests/test-config-env.py
--- a/tests/test-config-env.py
+++ b/tests/test-config-env.py
@@ -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):



To: martinvonz, #hg-reviewers, indygreg
Cc: mercurial-devel


More information about the Mercurial-devel mailing list