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

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

Issue 15087006: Docserver: there is only one. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: epic rebase Created 7 years, 5 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
Index: chrome/common/extensions/docs/server2/instance_servlet_test.py
diff --git a/chrome/common/extensions/docs/server2/instance_servlet_test.py b/chrome/common/extensions/docs/server2/instance_servlet_test.py
index 99252e22ef46db9c97a68b7d92cfedcdb4204037..8d9abc3b496f4fe62439783ea52cd5f713ecc64a 100755
--- a/chrome/common/extensions/docs/server2/instance_servlet_test.py
+++ b/chrome/common/extensions/docs/server2/instance_servlet_test.py
@@ -12,6 +12,9 @@ from servlet import Request
from test_branch_utility import TestBranchUtility
from test_util import DisableLogging
+# XXX(kalman): what is this test supposed to be?
+# Create a test host file system creator which failz?
+
# NOTE(kalman): The ObjectStore created by the InstanceServlet is backed onto
# our fake AppEngine memcache/datastore, so the tests aren't isolated.
class _TestDelegate(InstanceServlet.Delegate):
@@ -35,19 +38,19 @@ class InstanceServletTest(unittest.TestCase):
def testHostFileSystemNotAccessed(self):
delegate = _TestDelegate(_FailOnAccessFileSystem)
constructor = InstanceServlet.GetConstructor(delegate_for_test=delegate)
- def test_path(path):
+ def test_path(path, status=404):
response = constructor(Request.ForTest(path)).Get()
- self.assertEqual(404, response.status)
+ self.assertEqual(status, response.status)
test_path('extensions/storage.html')
test_path('apps/storage.html')
test_path('extensions/examples/foo.zip')
test_path('extensions/examples/foo.html')
test_path('static/foo.css')
- test_path('beta/extensions/storage.html')
- test_path('beta/apps/storage.html')
- test_path('beta/extensions/examples/foo.zip')
- test_path('beta/extensions/examples/foo.html')
- test_path('beta/static/foo.css')
+ test_path('beta/extensions/storage.html', status=301)
+ test_path('beta/apps/storage.html', status=301)
+ test_path('beta/extensions/examples/foo.zip', status=301)
+ test_path('beta/extensions/examples/foo.html', status=301)
+ test_path('beta/static/foo.css', status=301)
if __name__ == '__main__':
unittest.main()
« no previous file with comments | « chrome/common/extensions/docs/server2/instance_servlet.py ('k') | chrome/common/extensions/docs/server2/integration_test.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698