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

Side by Side Diff: chrome/browser/ui/extensions/extension_installed_bubble_browsertest.cc

Issue 1779343002: [Extensions] Update installed bubble for extensions with synthesized actions (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@2661
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
« no previous file with comments | « chrome/browser/ui/extensions/extension_installed_bubble.cc ('k') | chrome/chrome_tests.gypi » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 "chrome/browser/extensions/extension_action_test_util.h"
6 #include "chrome/browser/extensions/extension_browsertest.h"
7 #include "chrome/browser/extensions/extension_service.h"
8 #include "chrome/browser/ui/extensions/extension_installed_bubble.h"
9
10 using ExtensionInstalledBubbleBrowserTest = ExtensionBrowserTest;
11
12 IN_PROC_BROWSER_TEST_F(ExtensionInstalledBubbleBrowserTest,
13 DoNotShowHowToUseForSynthesizedActions) {
14 const SkBitmap kEmptyBitmap;
15 {
16 scoped_refptr<const extensions::Extension> extension =
17 extensions::extension_action_test_util::CreateActionExtension(
18 "No action", extensions::extension_action_test_util::NO_ACTION);
19 extension_service()->AddExtension(extension.get());
20 ExtensionInstalledBubble bubble(extension.get(), browser(), kEmptyBitmap);
21 bubble.Initialize();
22 EXPECT_EQ(0, bubble.options() & ExtensionInstalledBubble::HOW_TO_USE);
23 }
24 {
25 scoped_refptr<const extensions::Extension> extension =
26 extensions::extension_action_test_util::CreateActionExtension(
27 "Browser action",
28 extensions::extension_action_test_util::BROWSER_ACTION);
29 extension_service()->AddExtension(extension.get());
30 ExtensionInstalledBubble bubble(extension.get(), browser(), kEmptyBitmap);
31 bubble.Initialize();
32 EXPECT_NE(0, bubble.options() & ExtensionInstalledBubble::HOW_TO_USE);
33 }
34 {
35 scoped_refptr<const extensions::Extension> extension =
36 extensions::extension_action_test_util::CreateActionExtension(
37 "Page action", extensions::extension_action_test_util::PAGE_ACTION);
38 extension_service()->AddExtension(extension.get());
39 ExtensionInstalledBubble bubble(extension.get(), browser(), kEmptyBitmap);
40 bubble.Initialize();
41 EXPECT_NE(0, bubble.options() & ExtensionInstalledBubble::HOW_TO_USE);
42 }
43 }
OLDNEW
« no previous file with comments | « chrome/browser/ui/extensions/extension_installed_bubble.cc ('k') | chrome/chrome_tests.gypi » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698