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

Side by Side Diff: chrome/browser/extensions/activity_log/activity_log_unittest.cc

Issue 15812004: Remove the Activity Log UI (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 7 years, 6 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 (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 #include "base/command_line.h" 5 #include "base/command_line.h"
6 #include "base/memory/scoped_ptr.h" 6 #include "base/memory/scoped_ptr.h"
7 #include "base/synchronization/waitable_event.h" 7 #include "base/synchronization/waitable_event.h"
8 #include "chrome/browser/extensions/activity_log/activity_log.h" 8 #include "chrome/browser/extensions/activity_log/activity_log.h"
9 #include "chrome/browser/extensions/extension_service.h" 9 #include "chrome/browser/extensions/extension_service.h"
10 #include "chrome/browser/extensions/test_extension_system.h" 10 #include "chrome/browser/extensions/test_extension_system.h"
(...skipping 24 matching lines...) Expand all
35 35
36 virtual void SetUp() OVERRIDE { 36 virtual void SetUp() OVERRIDE {
37 ChromeRenderViewHostTestHarness::SetUp(); 37 ChromeRenderViewHostTestHarness::SetUp();
38 CommandLine command_line(CommandLine::NO_PROGRAM); 38 CommandLine command_line(CommandLine::NO_PROGRAM);
39 profile_ = 39 profile_ =
40 Profile::FromBrowserContext(web_contents()->GetBrowserContext()); 40 Profile::FromBrowserContext(web_contents()->GetBrowserContext());
41 extension_service_ = static_cast<TestExtensionSystem*>( 41 extension_service_ = static_cast<TestExtensionSystem*>(
42 ExtensionSystem::Get(profile_))->CreateExtensionService( 42 ExtensionSystem::Get(profile_))->CreateExtensionService(
43 &command_line, base::FilePath(), false); 43 &command_line, base::FilePath(), false);
44 CommandLine::ForCurrentProcess()->AppendSwitch( 44 CommandLine::ForCurrentProcess()->AppendSwitch(
45 switches::kEnableExtensionActivityUI); 45 switches::kEnableExtensionActivityLogging);
46 CommandLine::ForCurrentProcess()->AppendSwitch( 46 CommandLine::ForCurrentProcess()->AppendSwitch(
47 switches::kEnableExtensionActivityLogTesting); 47 switches::kEnableExtensionActivityLogTesting);
48 ActivityLog::RecomputeLoggingIsEnabled(); 48 ActivityLog::RecomputeLoggingIsEnabled();
49 } 49 }
50 50
51 virtual ~ActivityLogTest() { 51 virtual ~ActivityLogTest() {
52 MessageLoop::current()->PostTask(FROM_HERE, MessageLoop::QuitClosure()); 52 MessageLoop::current()->PostTask(FROM_HERE, MessageLoop::QuitClosure());
53 MessageLoop::current()->Run(); 53 MessageLoop::current()->Run();
54 } 54 }
55 55
(...skipping 120 matching lines...) Expand 10 before | Expand all | Expand 10 after
176 args->Set(0, new base::StringValue("hello")); 176 args->Set(0, new base::StringValue("hello"));
177 args->Set(1, new base::StringValue("world")); 177 args->Set(1, new base::StringValue("world"));
178 activity_log->LogAPIAction( 178 activity_log->LogAPIAction(
179 extension, std::string("extension.connect"), args.get(), std::string()); 179 extension, std::string("extension.connect"), args.get(), std::string());
180 activity_log->GetActions( 180 activity_log->GetActions(
181 extension->id(), 0, base::Bind(ActivityLogTest::Arguments_Present)); 181 extension->id(), 0, base::Bind(ActivityLogTest::Arguments_Present));
182 } 182 }
183 183
184 } // namespace extensions 184 } // namespace extensions
185 185
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698