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

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

Issue 68873003: Docserver: Serve docs out of src/ not src/chrome/common/extensions. This allows (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: fix samples Created 7 years, 1 month 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/content_providers_test.py
diff --git a/chrome/common/extensions/docs/server2/content_providers_test.py b/chrome/common/extensions/docs/server2/content_providers_test.py
index 72322cdc6cb31edf1c2571af7e47e1bb4f013bd2..6e451feac37f2b5784ed70b626b439ee91031702 100755
--- a/chrome/common/extensions/docs/server2/content_providers_test.py
+++ b/chrome/common/extensions/docs/server2/content_providers_test.py
@@ -8,6 +8,7 @@ import unittest
from compiled_file_system import CompiledFileSystem
from content_providers import ContentProviders
+from extensions_paths import EXTENSIONS
from object_store_creator import ObjectStoreCreator
from test_file_system import TestFileSystem
from test_util import DisableLogging
@@ -19,19 +20,20 @@ _HOST = 'https://developer.chrome.com'
_CONTENT_PROVIDERS = {
'apples': {
'chromium': {
- 'dir': 'apples'
+ 'dir': 'chrome/common/extensions/apples'
},
'serveFrom': 'apples-dir',
},
'bananas': {
'serveFrom': '',
'chromium': {
- 'dir': ''
+ 'dir': 'chrome/common/extensions'
},
},
'github-provider': {
'serveFrom': 'gh',
'github': {
+ 'dir': 'chrome/common/extensions',
'owner': 'GoogleChrome',
'repo': 'hello-world',
},
@@ -39,7 +41,7 @@ _CONTENT_PROVIDERS = {
'github-provider-with-dir': {
'serveFrom': 'gh2',
'github': {
- 'dir': 'tomatoes/are/a',
+ 'dir': 'chrome/common/extensions/tomatoes/are/a',
'owner': 'SomeOwner',
'repo': 'some-repo',
},
@@ -47,7 +49,7 @@ _CONTENT_PROVIDERS = {
'tomatoes': {
'serveFrom': 'tomatoes-dir/are/a',
'chromium': {
- 'dir': 'tomatoes/are/a'
+ 'dir': 'chrome/common/extensions/tomatoes/are/a'
},
},
}
@@ -101,7 +103,7 @@ class _MockGithubFileSystemProvider(object):
class ContentProvidersTest(unittest.TestCase):
def setUp(self):
- test_file_system = TestFileSystem(_FILE_SYSTEM_DATA)
+ test_file_system = TestFileSystem(_FILE_SYSTEM_DATA, relative_to=EXTENSIONS)
self._github_fs_provider = _MockGithubFileSystemProvider(test_file_system)
self._content_providers = ContentProviders(
CompiledFileSystem.Factory(ObjectStoreCreator.ForTest()),
@@ -127,7 +129,7 @@ class ContentProvidersTest(unittest.TestCase):
'cherry tomatoes',
provider.GetContentAndType(_HOST, 'fruit/cherry.txt').Get().content)
- def testEmptyRootPath(self):
+ def testParentRootPath(self):
provider = self._content_providers.GetByName('bananas')
self.assertEqual(
'gala apples',
« no previous file with comments | « chrome/common/extensions/docs/server2/content_providers.py ('k') | chrome/common/extensions/docs/server2/cron.yaml » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698