From 41453a9a025a4d77cd91a704d746966023943ec8 Mon Sep 17 00:00:00 2001 From: Phil Cohen Date: Fri, 25 May 2018 18:02:47 -0700 Subject: [PATCH] fix the build Summary: Reports of my competence were greatly overstated. Reviewed By: quark-zju Differential Revision: D8174059 fbshipit-source-id: 25de102f9fa7b47f9654ae0219e5373e9111b197 --- tests/test-fb-hgext-sampling.t | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/tests/test-fb-hgext-sampling.t b/tests/test-fb-hgext-sampling.t index d6b09e5e06..032cbc067d 100644 --- a/tests/test-fb-hgext-sampling.t +++ b/tests/test-fb-hgext-sampling.t @@ -84,8 +84,9 @@ Test topdir logging: $ setconfig sampling.logtopdir=True $ setconfig sampling.key.command_info=command_info $ hg st > /dev/null - hiatexit handler executed + atexit handler executed + >>> import json >>> with open("$LOGDIR/samplingpath.txt") as f: ... data = f.read().strip("\0").split("\0") - >>> print([d for d in data if "topdir" in d]) - ['{"category": "command_info", "data": {"topdir": "a_topdir", "metrics_type": "command_info"}}'] + >>> print([json.loads(d)["data"]["topdir"] for d in data if "topdir" in d]) + [u'a_topdir']