Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(7836)

Unified Diff: chrome/common/extensions/docs/server2/template_data_source_test.py

Issue 14273035: Docserver: refactor the Handler/ServerInstance relationship into a servlet (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: done Created 7 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « chrome/common/extensions/docs/server2/servlet.py ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: chrome/common/extensions/docs/server2/template_data_source_test.py
diff --git a/chrome/common/extensions/docs/server2/template_data_source_test.py b/chrome/common/extensions/docs/server2/template_data_source_test.py
index 9a5d438725d00b406b1f919829abfd619d6385d6..745e3731b50ab082659b116e3ecaf0bbec53c416 100755
--- a/chrome/common/extensions/docs/server2/template_data_source_test.py
+++ b/chrome/common/extensions/docs/server2/template_data_source_test.py
@@ -16,9 +16,7 @@ from reference_resolver import ReferenceResolver
from template_data_source import TemplateDataSource
from test_util import DisableLogging
from third_party.handlebar import Handlebar
-
-class _FakeRequest(object):
- pass
+from servlet import Request
class _FakeFactory(object):
def __init__(self, input_dict=None):
@@ -62,7 +60,8 @@ class TemplateDataSourceTest(unittest.TestCase):
ObjectStoreCreator.TestFactory())
@DisableLogging('error') # "was never set" error
def create_from_factory(factory):
- return factory.Create(_FakeRequest(), 'extensions/foo')
+ path = 'extensions/foo'
+ return factory.Create(Request(path, {}), path)
return create_from_factory(TemplateDataSource.Factory(
'fake_channel',
api_data_factory,
« no previous file with comments | « chrome/common/extensions/docs/server2/servlet.py ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698