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

Side by Side Diff: mojo/shell/background/tests/test_application_catalog_store.cc

Issue 1775243002: Rename PackageManager->Catalog. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@42cpi
Patch Set: . Created 4 years, 9 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 unified diff | Download patch
OLDNEW
(Empty)
1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file.
4
5 #include "mojo/shell/background/tests/test_application_catalog_store.h"
6
7 using package_manager::ApplicationCatalogStore;
8
9 namespace mojo {
10 namespace shell {
11
12 TestApplicationCatalogStore::TestApplicationCatalogStore(
13 scoped_ptr<base::ListValue> store)
14 : store_(std::move(store)) {}
15
16 TestApplicationCatalogStore::~TestApplicationCatalogStore() {}
17
18 const base::ListValue* TestApplicationCatalogStore::GetStore() {
19 get_store_called_ = true;
20 return store_.get();
21 }
22
23 void TestApplicationCatalogStore::UpdateStore(
24 scoped_ptr<base::ListValue> store) {}
25
26 scoped_ptr<base::DictionaryValue> BuildPermissiveSerializedAppInfo(
27 const std::string& name,
28 const std::string& display_name) {
29 scoped_ptr<base::DictionaryValue> app(new base::DictionaryValue);
30 app->SetString(ApplicationCatalogStore::kNameKey, name);
31 app->SetString(ApplicationCatalogStore::kDisplayNameKey, display_name);
32
33 scoped_ptr<base::DictionaryValue> capabilities(new base::DictionaryValue);
34 scoped_ptr<base::ListValue> interfaces(new base::ListValue);
35 interfaces->AppendString("*");
36 capabilities->Set("*", std::move(interfaces));
37
38 app->Set(ApplicationCatalogStore::kCapabilitiesKey, std::move(capabilities));
39
40 return app;
41 }
42
43 } // namespace shell
44 } // namespace mojo
OLDNEW
« no previous file with comments | « mojo/shell/background/tests/test_application_catalog_store.h ('k') | mojo/shell/background/tests/test_catalog_store.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698