Mercurial > public > mercurial-scm > hg-stable
diff tests/flagprocessorext.py @ 42987:bd5858c28bbe
flagprocessors: have the read transform function return side data (API)
This makes it possible for flag processors to -read- flag data.
Differential Revision: https://phab.mercurial-scm.org/D6813
author | Pierre-Yves David <pierre-yves.david@octobus.net> |
---|---|
date | Wed, 04 Sep 2019 00:34:03 +0200 |
parents | 6d61be152c55 |
children | f4caf910669e |
line wrap: on
line diff
--- a/tests/flagprocessorext.py Wed Sep 04 00:13:45 2019 +0200 +++ b/tests/flagprocessorext.py Wed Sep 04 00:34:03 2019 +0200 @@ -33,17 +33,20 @@ def noopdonothing(self, text): return (text, True) +def noopdonothingread(self, text): + return (text, True, {}) + def b64encode(self, text): return (base64.b64encode(text), False) def b64decode(self, text): - return (base64.b64decode(text), True) + return (base64.b64decode(text), True, {}) def gzipcompress(self, text): return (zlib.compress(text), False) def gzipdecompress(self, text): - return (zlib.decompress(text), True) + return (zlib.decompress(text), True, {}) def supportedoutgoingversions(orig, repo): versions = orig(repo) @@ -116,7 +119,7 @@ flagutil.addflagprocessor( REVIDX_NOOP, ( - noopdonothing, + noopdonothingread, noopdonothing, validatehash, )