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

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

Issue 48643003: Moved extension and value builder code to extensions component. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase again Created 7 years, 1 month 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 "base/values.h" 5 #include "base/values.h"
6 #include "chrome/browser/extensions/activity_log/activity_action_constants.h" 6 #include "chrome/browser/extensions/activity_log/activity_action_constants.h"
7 #include "chrome/browser/extensions/activity_log/activity_actions.h" 7 #include "chrome/browser/extensions/activity_log/activity_actions.h"
8 #include "chrome/browser/extensions/activity_log/activity_log_policy.h" 8 #include "chrome/browser/extensions/activity_log/activity_log_policy.h"
9 #include "chrome/browser/extensions/activity_log/web_request_constants.h" 9 #include "chrome/browser/extensions/activity_log/web_request_constants.h"
10 #include "chrome/common/extensions/value_builder.h" 10 #include "extensions/common/value_builder.h"
11 #include "testing/gtest/include/gtest/gtest.h" 11 #include "testing/gtest/include/gtest/gtest.h"
12 12
13 namespace extensions { 13 namespace extensions {
14 14
15 class ActivityLogPolicyUtilTest : public testing::Test {}; 15 class ActivityLogPolicyUtilTest : public testing::Test {};
16 16
17 // Test that incognito values are stripped, and non-incognito ones aren't. 17 // Test that incognito values are stripped, and non-incognito ones aren't.
18 TEST_F(ActivityLogPolicyUtilTest, StripPrivacySensitive) { 18 TEST_F(ActivityLogPolicyUtilTest, StripPrivacySensitive) {
19 scoped_refptr<Action> action = 19 scoped_refptr<Action> action =
20 new Action("punky", 20 new Action("punky",
(...skipping 66 matching lines...) Expand 10 before | Expand all | Expand 10 after
87 new Action("punky", 87 new Action("punky",
88 base::Time::Now(), 88 base::Time::Now(),
89 Action::ACTION_API_CALL, 89 Action::ACTION_API_CALL,
90 "tabs.executeScript"); 90 "tabs.executeScript");
91 action->ParsePageUrl("<incognito>http://www.google.com/"); 91 action->ParsePageUrl("<incognito>http://www.google.com/");
92 EXPECT_EQ("http://www.google.com/", action->page_url().spec()); 92 EXPECT_EQ("http://www.google.com/", action->page_url().spec());
93 EXPECT_TRUE(action->page_incognito()); 93 EXPECT_TRUE(action->page_incognito());
94 } 94 }
95 95
96 } // namespace extensions 96 } // namespace extensions
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698