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

Side by Side Diff: chrome/common/extensions/extension_unittest.cc

Issue 10697017: Tabs Extension: Implementation of tabs.duplicate api. (Closed) Base URL: http://src.chromium.org/svn/trunk/src/
Patch Set: Created 8 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 (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 "chrome/common/extensions/extension.h" 5 #include "chrome/common/extensions/extension.h"
6 6
7 #include "base/format_macros.h" 7 #include "base/format_macros.h"
8 #include "base/file_path.h" 8 #include "base/file_path.h"
9 #include "base/file_util.h" 9 #include "base/file_util.h"
10 #include "base/json/json_file_value_serializer.h" 10 #include "base/json/json_file_value_serializer.h"
(...skipping 537 matching lines...) Expand 10 before | Expand all | Expand 10 after
548 // Some negative tests. 548 // Some negative tests.
549 { "bookmarks", false }, 549 { "bookmarks", false },
550 { "cookies", false }, 550 { "cookies", false },
551 { "history", false }, 551 { "history", false },
552 { "tabs.onUpdated", false }, 552 { "tabs.onUpdated", false },
553 // Make sure we find the module name after stripping '.' and '/'. 553 // Make sure we find the module name after stripping '.' and '/'.
554 { "browserAction/abcd/onClick", true }, 554 { "browserAction/abcd/onClick", true },
555 { "browserAction.abcd.onClick", true }, 555 { "browserAction.abcd.onClick", true },
556 // Test Tabs functions. 556 // Test Tabs functions.
557 { "tabs.create", true}, 557 { "tabs.create", true},
558 { "tabs.duplicate", true},
558 { "tabs.onRemoved", true}, 559 { "tabs.onRemoved", true},
559 { "tabs.remove", true}, 560 { "tabs.remove", true},
560 { "tabs.update", true}, 561 { "tabs.update", true},
561 { "tabs.getSelected", false}, 562 { "tabs.getSelected", false},
562 // Test getPermissionWarnings functions. Only one requires permissions. 563 // Test getPermissionWarnings functions. Only one requires permissions.
563 { "management.getPermissionWarningsById", false }, 564 { "management.getPermissionWarningsById", false },
564 { "management.getPermissionWarningsByManifest", true }, 565 { "management.getPermissionWarningsByManifest", true },
565 }; 566 };
566 567
567 scoped_refptr<Extension> extension; 568 scoped_refptr<Extension> extension;
(...skipping 543 matching lines...) Expand 10 before | Expand all | Expand 10 after
1111 } 1112 }
1112 1113
1113 TEST(ExtensionTest, GetSyncTypeExtensionWithTwoPlugins) { 1114 TEST(ExtensionTest, GetSyncTypeExtensionWithTwoPlugins) {
1114 scoped_refptr<Extension> extension( 1115 scoped_refptr<Extension> extension(
1115 MakeSyncTestExtension(EXTENSION, GURL(), GURL(), 1116 MakeSyncTestExtension(EXTENSION, GURL(), GURL(),
1116 Extension::INTERNAL, 2, FilePath())); 1117 Extension::INTERNAL, 2, FilePath()));
1117 if (extension) 1118 if (extension)
1118 EXPECT_EQ(extension->GetSyncType(), Extension::SYNC_TYPE_NONE); 1119 EXPECT_EQ(extension->GetSyncType(), Extension::SYNC_TYPE_NONE);
1119 } 1120 }
1120 #endif // !defined(OS_CHROMEOS) 1121 #endif // !defined(OS_CHROMEOS)
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698