diff options
author | kalman@chromium.org <kalman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-04-25 04:36:07 +0000 |
---|---|---|
committer | kalman@chromium.org <kalman@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2013-04-25 04:36:07 +0000 |
commit | 4ab445887647350e1dfb89af64865265d382e1c6 (patch) | |
tree | 70b4cb50f30a0bf31ef4a4da7259b9bef3b0d482 /chrome/common/extensions/docs/server2/integration_test.py | |
parent | 7271f64d2987cb7a3fb38cb0cf1334c9f871df8e (diff) | |
download | chromium_src-4ab445887647350e1dfb89af64865265d382e1c6.zip chromium_src-4ab445887647350e1dfb89af64865265d382e1c6.tar.gz chromium_src-4ab445887647350e1dfb89af64865265d382e1c6.tar.bz2 |
Docserver: greatly improve the error logging by (a) preserving the stack traces in Futures,
(b) actually logging the stack trace, and (c) respecting DeadlineExceededErrors.
BUG=167432
Review URL: https://codereview.chromium.org/14333015
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@196309 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/common/extensions/docs/server2/integration_test.py')
-rwxr-xr-x | chrome/common/extensions/docs/server2/integration_test.py | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/chrome/common/extensions/docs/server2/integration_test.py b/chrome/common/extensions/docs/server2/integration_test.py index 262e8ee..7f86804 100755 --- a/chrome/common/extensions/docs/server2/integration_test.py +++ b/chrome/common/extensions/docs/server2/integration_test.py @@ -8,14 +8,17 @@ import build_server build_server.main() -from handler import Handler -from local_renderer import LocalRenderer +import logging import optparse import os import sys import time import unittest +from handler import Handler +from local_renderer import LocalRenderer +from test_util import DisableLogging + # Arguments set up if __main__ specifies them. _BASE_PATH = os.path.join( os.path.abspath(os.path.dirname(__file__)), os.pardir, os.pardir) @@ -81,7 +84,6 @@ class IntegrationTest(unittest.TestCase): ''' if _EXPLICIT_TEST_FILES is None: return - print('Rendering %s explicit files...' % len(_EXPLICIT_TEST_FILES)) for filename in _EXPLICIT_TEST_FILES: print('Rendering %s...' % filename) start_time = time.time() @@ -93,9 +95,10 @@ class IntegrationTest(unittest.TestCase): finally: print('Took %s seconds' % (time.time() - start_time)) + @DisableLogging('warning') def testFileNotFound(self): render_content, render_status, _ = self._renderer.Render( - '/extensions/notfound.html') + '/extensions/notfound.html', always_online=True) self.assertEqual(404, render_status) if __name__ == '__main__': |