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 | 4 |
5 from api_data_source import APIDataSource | 5 from api_data_source import APIDataSource |
6 from api_list_data_source import APIListDataSource | 6 from api_list_data_source import APIListDataSource |
7 from api_models import APIModels | 7 from api_models import APIModels |
8 from availability_finder import AvailabilityFinder | 8 from availability_finder import AvailabilityFinder |
9 from compiled_file_system import CompiledFileSystem | 9 from compiled_file_system import CompiledFileSystem |
10 from directory_zipper import DirectoryZipper | 10 from directory_zipper import DirectoryZipper |
(...skipping 68 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
79 self.compiled_fs_factory, | 79 self.compiled_fs_factory, |
80 host_fs_at_trunk) | 80 host_fs_at_trunk) |
81 | 81 |
82 self.availability_finder = AvailabilityFinder( | 82 self.availability_finder = AvailabilityFinder( |
83 branch_utility, | 83 branch_utility, |
84 compiled_fs_factory, | 84 compiled_fs_factory, |
85 self.host_file_system_iterator, | 85 self.host_file_system_iterator, |
86 host_fs_at_trunk, | 86 host_fs_at_trunk, |
87 object_store_creator) | 87 object_store_creator) |
88 | 88 |
89 self.api_list_data_source_factory = APIListDataSource.Factory( | |
90 self.compiled_fs_factory, | |
91 host_fs_at_trunk, | |
92 svn_constants.PUBLIC_TEMPLATE_PATH, | |
93 self.features_bundle, | |
94 self.object_store_creator) | |
95 | |
96 self.api_data_source_factory = APIDataSource.Factory( | 89 self.api_data_source_factory = APIDataSource.Factory( |
97 self.compiled_fs_factory, | 90 self.compiled_fs_factory, |
98 host_fs_at_trunk, | 91 host_fs_at_trunk, |
99 svn_constants.API_PATH, | 92 svn_constants.API_PATH, |
100 self.availability_finder, | 93 self.availability_finder, |
101 branch_utility) | 94 branch_utility) |
102 | 95 |
| 96 self.api_list_data_source_factory = APIListDataSource.Factory( |
| 97 self.compiled_fs_factory, |
| 98 host_fs_at_trunk, |
| 99 svn_constants.PUBLIC_TEMPLATE_PATH, |
| 100 self.features_bundle, |
| 101 self.object_store_creator, |
| 102 self.api_models, |
| 103 self.availability_finder) |
| 104 |
103 self.ref_resolver_factory = ReferenceResolver.Factory( | 105 self.ref_resolver_factory = ReferenceResolver.Factory( |
104 self.api_data_source_factory, | 106 self.api_data_source_factory, |
105 self.api_list_data_source_factory, | 107 self.api_list_data_source_factory, |
106 object_store_creator) | 108 object_store_creator) |
107 | 109 |
108 self.api_data_source_factory.SetReferenceResolverFactory( | 110 self.api_data_source_factory.SetReferenceResolverFactory( |
109 self.ref_resolver_factory) | 111 self.ref_resolver_factory) |
110 | 112 |
111 # Note: samples are super slow in the dev server because it doesn't support | 113 # Note: samples are super slow in the dev server because it doesn't support |
112 # async fetch, so disable them. | 114 # async fetch, so disable them. |
(...skipping 59 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
172 object_store_creator = ObjectStoreCreator(start_empty=False, | 174 object_store_creator = ObjectStoreCreator(start_empty=False, |
173 store_type=TestObjectStore) | 175 store_type=TestObjectStore) |
174 host_file_system_provider = HostFileSystemProvider.ForLocal( | 176 host_file_system_provider = HostFileSystemProvider.ForLocal( |
175 object_store_creator) | 177 object_store_creator) |
176 return ServerInstance( | 178 return ServerInstance( |
177 object_store_creator, | 179 object_store_creator, |
178 CompiledFileSystem.Factory(object_store_creator), | 180 CompiledFileSystem.Factory(object_store_creator), |
179 TestBranchUtility.CreateWithCannedData(), | 181 TestBranchUtility.CreateWithCannedData(), |
180 host_file_system_provider, | 182 host_file_system_provider, |
181 GithubFileSystemProvider.ForEmpty()) | 183 GithubFileSystemProvider.ForEmpty()) |
OLD | NEW |