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

Side by Side Diff: chrome/browser/sync/glue/extensions_activity_monitor_unittest.cc

Issue 22794012: Rename extension_manifest_keys namespace to extensions::manifest_keys. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: rebase Created 7 years, 4 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 | Annotate | Revision Log
OLDNEW
1 // Copyright 2013 The Chromium Authors. All rights reserved. 1 // Copyright 2013 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 #include "chrome/browser/sync/glue/extensions_activity_monitor.h" 5 #include "chrome/browser/sync/glue/extensions_activity_monitor.h"
6 6
7 #include "base/files/file_path.h" 7 #include "base/files/file_path.h"
8 #include "base/message_loop/message_loop.h" 8 #include "base/message_loop/message_loop.h"
9 #include "base/path_service.h" 9 #include "base/path_service.h"
10 #include "base/values.h" 10 #include "base/values.h"
11 #include "chrome/browser/chrome_notification_types.h" 11 #include "chrome/browser/chrome_notification_types.h"
12 #include "chrome/browser/extensions/api/bookmarks/bookmarks_api.h" 12 #include "chrome/browser/extensions/api/bookmarks/bookmarks_api.h"
13 #include "chrome/common/chrome_paths.h" 13 #include "chrome/common/chrome_paths.h"
14 #include "chrome/common/extensions/extension.h" 14 #include "chrome/common/extensions/extension.h"
15 #include "chrome/common/extensions/extension_manifest_constants.h"
16 #include "content/public/browser/notification_service.h" 15 #include "content/public/browser/notification_service.h"
17 #include "content/public/test/test_browser_thread.h" 16 #include "content/public/test/test_browser_thread.h"
17 #include "extensions/common/manifest_constants.h"
18 #include "sync/util/extensions_activity.h" 18 #include "sync/util/extensions_activity.h"
19 #include "testing/gtest/include/gtest/gtest.h" 19 #include "testing/gtest/include/gtest/gtest.h"
20 20
21 using extensions::Extension; 21 using extensions::Extension;
22 22
23 namespace browser_sync { 23 namespace browser_sync {
24 24
25 namespace { 25 namespace {
26 26
27 using content::BrowserThread; 27 using content::BrowserThread;
28 namespace keys = extension_manifest_keys; 28 namespace keys = extensions::manifest_keys;
29 29
30 // Create and return an extension with the given path. 30 // Create and return an extension with the given path.
31 scoped_refptr<Extension> MakeExtension(const std::string& name) { 31 scoped_refptr<Extension> MakeExtension(const std::string& name) {
32 base::FilePath path; 32 base::FilePath path;
33 EXPECT_TRUE(PathService::Get(chrome::DIR_TEST_DATA, &path)); 33 EXPECT_TRUE(PathService::Get(chrome::DIR_TEST_DATA, &path));
34 path = path.AppendASCII(name); 34 path = path.AppendASCII(name);
35 35
36 DictionaryValue value; 36 DictionaryValue value;
37 value.SetString(keys::kVersion, "1.0.0.0"); 37 value.SetString(keys::kVersion, "1.0.0.0");
38 value.SetString(keys::kName, name); 38 value.SetString(keys::kName, name);
(...skipping 127 matching lines...) Expand 10 before | Expand all | Expand 10 after
166 FireBookmarksApiEvent<extensions::BookmarksCreateFunction>(extension1_, 3); 166 FireBookmarksApiEvent<extensions::BookmarksCreateFunction>(extension1_, 3);
167 monitor_.GetExtensionsActivity()->GetAndClearRecords(&results); 167 monitor_.GetExtensionsActivity()->GetAndClearRecords(&results);
168 168
169 EXPECT_EQ(1U, results.size()); 169 EXPECT_EQ(1U, results.size());
170 EXPECT_EQ(3U, results[id1_].bookmark_write_count); 170 EXPECT_EQ(3U, results[id1_].bookmark_write_count);
171 } 171 }
172 172
173 } // namespace 173 } // namespace
174 174
175 } // namespace browser_sync 175 } // namespace browser_sync
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698