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

Unified Diff: services/shell/background/tests/test_catalog_store.cc

Issue 2419723002: Move services/shell to services/service_manager (Closed)
Patch Set: rebase Created 4 years, 2 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: services/shell/background/tests/test_catalog_store.cc
diff --git a/services/shell/background/tests/test_catalog_store.cc b/services/shell/background/tests/test_catalog_store.cc
deleted file mode 100644
index e8a4194d9da20b8741a2932f5e5225758969b54f..0000000000000000000000000000000000000000
--- a/services/shell/background/tests/test_catalog_store.cc
+++ /dev/null
@@ -1,55 +0,0 @@
-// Copyright 2016 The Chromium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-#include "services/shell/background/tests/test_catalog_store.h"
-
-using catalog::Store;
-
-namespace shell {
-
-TestCatalogStore::TestCatalogStore(std::unique_ptr<base::ListValue> store)
- : store_(std::move(store)) {}
-
-TestCatalogStore::~TestCatalogStore() {}
-
-const base::ListValue* TestCatalogStore::GetStore() {
- get_store_called_ = true;
- return store_.get();
-}
-
-void TestCatalogStore::UpdateStore(std::unique_ptr<base::ListValue> store) {}
-
-std::unique_ptr<base::DictionaryValue> BuildPermissiveSerializedAppInfo(
- const std::string& name,
- const std::string& display_name) {
- std::unique_ptr<base::DictionaryValue> app(new base::DictionaryValue);
- app->SetString(Store::kNameKey, name);
- app->SetString(Store::kDisplayNameKey, display_name);
- app->SetInteger(Store::kManifestVersionKey, 1);
-
- std::unique_ptr<base::DictionaryValue> capabilities(
- new base::DictionaryValue);
- std::unique_ptr<base::DictionaryValue> provided_classes(
- new base::DictionaryValue);
- std::unique_ptr<base::ListValue> provided_classes_list(
- new base::ListValue);
- provided_classes_list->AppendString("shell::mojom::TestService");
- provided_classes->Set("shell:test_service", std::move(provided_classes_list));
- capabilities->Set(Store::kCapabilities_ProvidedKey,
- std::move(provided_classes));
- std::unique_ptr<base::DictionaryValue> required_capabilities(
- new base::DictionaryValue);
- std::unique_ptr<base::DictionaryValue> classes_dictionary(
- new base::DictionaryValue);
- std::unique_ptr<base::ListValue> classes_list(new base::ListValue);
- classes_list->AppendString("shell:test_service");
- classes_dictionary->Set("classes", std::move(classes_list));
- required_capabilities->Set("*", std::move(classes_dictionary));
- capabilities->Set(Store::kCapabilities_RequiredKey,
- std::move(required_capabilities));
- app->Set(Store::kCapabilitiesKey, std::move(capabilities));
- return app;
-}
-
-} // namespace shell
« no previous file with comments | « services/shell/background/tests/test_catalog_store.h ('k') | services/shell/background/tests/test_manifest.json » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698