OLD | NEW |
1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. | 1 # Copyright (c) 2012 The Chromium Authors. All rights reserved. |
2 # Use of this source code is governed by a BSD-style license that can be | 2 # Use of this source code is governed by a BSD-style license that can be |
3 # found in the LICENSE file. | 3 # found in the LICENSE file. |
4 | 4 |
5 import cStringIO | 5 import cStringIO |
6 import json | 6 import json |
7 import logging | 7 import logging |
8 import os | 8 import os |
9 import unittest | 9 import unittest |
10 | 10 |
(...skipping 54 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
65 '"bar"', | 65 '"bar"', |
66 '"baz"']) | 66 '"baz"']) |
67 f = cStringIO.StringIO() | 67 f = cStringIO.StringIO() |
68 ri.Serialize(f) | 68 ri.Serialize(f) |
69 v = f.getvalue() | 69 v = f.getvalue() |
70 | 70 |
71 j = json.loads(v) | 71 j = json.loads(v) |
72 assert 'traceEvents' in j | 72 assert 'traceEvents' in j |
73 self.assertEquals(j['traceEvents'], | 73 self.assertEquals(j['traceEvents'], |
74 ['foo', 'bar', 'baz']) | 74 ['foo', 'bar', 'baz']) |
OLD | NEW |