[lit] Format JSONMetricValue strings better.

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@226672 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Eric Fiselier 2015-01-21 16:38:31 +00:00
parent bdcc4ec129
commit b727b13f61

View File

@ -91,7 +91,8 @@ class JSONMetricValue(MetricValue):
self.value = value
def format(self):
return str(self.value)
e = JSONEncoder(indent=2, sort_keys=True)
return e.encode(self.value)
def todata(self):
return self.value