perfdatapack: fix tests

Summary: Recently-added perfdatapack breaks `test-contrib-perf` and `test-check-code`.

Reviewed By: pkaush

Differential Revision: D9195509

fbshipit-source-id: 023a89bb25ca3b387d6bf5684282910dd62611fe
This commit is contained in:
Mark Thomas 2018-08-07 08:35:29 -07:00 committed by Facebook Github Bot
parent d2be4f57d0
commit a0e7e9f5c2
2 changed files with 5 additions and 4 deletions

View File

@ -464,20 +464,20 @@ def perfdatapack(ui, repo, packpath, **opts):
from hgext.remotefilelog.datapack import datapack
keys = list(iter(datapack(packpath)))
ui.write("\nGetMissing (Key Count: %s)\n" % len(keys))
ui.write(("\nGetMissing (Key Count: %s)\n") % len(keys))
_packtestfn(ui, packpath, opts, lambda pack: pack.getmissing(keys))
partkeys = keys[:100]
ui.write("\nGetMissing (Key Count: %s)\n" % len(partkeys))
ui.write(("\nGetMissing (Key Count: %s)\n") % len(partkeys))
_packtestfn(ui, packpath, opts, lambda pack: pack.getmissing(partkeys))
key = keys[0]
ui.write("\nGet\n")
ui.write(("\nGet\n"))
def f(pack):
pack.getdelta(*key)
_packtestfn(ui, packpath, opts, f)
ui.write("\nMark Ledger (Key Count: %s)\n" % len(keys))
ui.write(("\nMark Ledger (Key Count: %s)\n") % len(keys))
from hgext.remotefilelog.repack import repackledger
def f(pack):
ledger = repackledger()

View File

@ -63,6 +63,7 @@ perfstatus
perfchangeset
(no help text available)
perfctxfiles (no help text available)
perfdatapack (no help text available)
perfdiffwd Profile diff of working directory changes
perfdirfoldmap
(no help text available)