Patchwork D8564: fakemergerecord: get mergestate via context

login
register
mail settings
Submitter phabricator
Date May 18, 2020, 10:10 p.m.
Message ID <differential-rev-PHID-DREV-vq5f4rnys3reshevtqkj-req@mercurial-scm.org>
Download mbox | patch
Permalink /patch/46351/
State New
Headers show

Comments

phabricator - May 18, 2020, 10:10 p.m.
durin42 created this revision.
Herald added a reviewer: hg-reviewers.
Herald added a subscriber: mercurial-patches.

REPOSITORY
  rHG Mercurial

BRANCH
  default

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

AFFECTED FILES
  tests/fakemergerecord.py

CHANGE DETAILS




To: durin42, #hg-reviewers
Cc: mercurial-patches, mercurial-devel

Patch

diff --git a/tests/fakemergerecord.py b/tests/fakemergerecord.py
--- a/tests/fakemergerecord.py
+++ b/tests/fakemergerecord.py
@@ -4,10 +4,7 @@ 
 
 from __future__ import absolute_import
 
-from mercurial import (
-    mergestate as mergestatemod,
-    registrar,
-)
+from mercurial import registrar
 
 cmdtable = {}
 command = registrar.command(cmdtable)
@@ -23,7 +20,7 @@ 
 )
 def fakemergerecord(ui, repo, *pats, **opts):
     with repo.wlock():
-        ms = mergestatemod.mergestate.read(repo)
+        ms = repo[None].mergestate()
         records = ms._makerecords()
         if opts.get('mandatory'):
             records.append((b'X', b'mandatory record'))