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 import os | 4 import os |
5 import re | 5 import re |
6 import StringIO | 6 import StringIO |
7 | 7 |
8 from telemetry import tab_test_case | 8 from telemetry import tab_test_case |
9 from telemetry import util | 9 from telemetry import util |
10 | 10 |
(...skipping 16 matching lines...) Expand all Loading... |
27 return current > initial | 27 return current > initial |
28 util.WaitFor(GotLog, 5) | 28 util.WaitFor(GotLog, 5) |
29 | 29 |
30 lines = [l for l in stream.getvalue().split('\n') if len(l)] | 30 lines = [l for l in stream.getvalue().split('\n') if len(l)] |
31 | 31 |
32 self.assertTrue(len(lines) >= 1) | 32 self.assertTrue(len(lines) >= 1) |
33 for l in lines: | 33 for l in lines: |
34 u_l = 'http://localhost:(\d+)/page_that_logs_to_console.html:9' | 34 u_l = 'http://localhost:(\d+)/page_that_logs_to_console.html:9' |
35 self.assertTrue(re.match('At %s: Hello, world' % u_l, l)) | 35 self.assertTrue(re.match('At %s: Hello, world' % u_l, l)) |
36 | 36 |
OLD | NEW |