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

Side by Side Diff: chrome/browser/extensions/extension_prefs_unittest.cc

Issue 6766002: Replace bools in extension creation with flags. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: For landing Created 9 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 | Annotate | Revision Log
OLDNEW
1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/memory/scoped_temp_dir.h" 5 #include "base/memory/scoped_temp_dir.h"
6 #include "base/message_loop.h" 6 #include "base/message_loop.h"
7 #include "base/path_service.h" 7 #include "base/path_service.h"
8 #include "base/stl_util-inl.h" 8 #include "base/stl_util-inl.h"
9 #include "base/string_number_conversions.h" 9 #include "base/string_number_conversions.h"
10 #include "base/stringprintf.h" 10 #include "base/stringprintf.h"
(...skipping 609 matching lines...) Expand 10 before | Expand all | Expand 10 after
620 ext3_(NULL), 620 ext3_(NULL),
621 installed() { 621 installed() {
622 DictionaryValue simple_dict; 622 DictionaryValue simple_dict;
623 std::string error; 623 std::string error;
624 624
625 simple_dict.SetString(keys::kVersion, "1.0.0.0"); 625 simple_dict.SetString(keys::kVersion, "1.0.0.0");
626 simple_dict.SetString(keys::kName, "unused"); 626 simple_dict.SetString(keys::kName, "unused");
627 627
628 ext1_scoped_ = Extension::Create( 628 ext1_scoped_ = Extension::Create(
629 prefs_.temp_dir().AppendASCII("ext1_"), Extension::EXTERNAL_PREF, 629 prefs_.temp_dir().AppendASCII("ext1_"), Extension::EXTERNAL_PREF,
630 simple_dict, false, true, &error); 630 simple_dict, Extension::STRICT_ERROR_CHECKS, &error);
631 ext2_scoped_ = Extension::Create( 631 ext2_scoped_ = Extension::Create(
632 prefs_.temp_dir().AppendASCII("ext2_"), Extension::EXTERNAL_PREF, 632 prefs_.temp_dir().AppendASCII("ext2_"), Extension::EXTERNAL_PREF,
633 simple_dict, false, true, &error); 633 simple_dict, Extension::STRICT_ERROR_CHECKS, &error);
634 ext3_scoped_ = Extension::Create( 634 ext3_scoped_ = Extension::Create(
635 prefs_.temp_dir().AppendASCII("ext3_"), Extension::EXTERNAL_PREF, 635 prefs_.temp_dir().AppendASCII("ext3_"), Extension::EXTERNAL_PREF,
636 simple_dict, false, true, &error); 636 simple_dict, Extension::STRICT_ERROR_CHECKS, &error);
637 637
638 ext1_ = ext1_scoped_.get(); 638 ext1_ = ext1_scoped_.get();
639 ext2_ = ext2_scoped_.get(); 639 ext2_ = ext2_scoped_.get();
640 ext3_ = ext3_scoped_.get(); 640 ext3_ = ext3_scoped_.get();
641 641
642 for (size_t i = 0; i < arraysize(installed); ++i) 642 for (size_t i = 0; i < arraysize(installed); ++i)
643 installed[i] = false; 643 installed[i] = false;
644 } 644 }
645 645
646 void RegisterPreferences() { 646 void RegisterPreferences() {
(...skipping 265 matching lines...) Expand 10 before | Expand all | Expand 10 after
912 testing::Mock::VerifyAndClearExpectations(v1i); 912 testing::Mock::VerifyAndClearExpectations(v1i);
913 testing::Mock::VerifyAndClearExpectations(v2); 913 testing::Mock::VerifyAndClearExpectations(v2);
914 testing::Mock::VerifyAndClearExpectations(v2i); 914 testing::Mock::VerifyAndClearExpectations(v2i);
915 } 915 }
916 916
917 virtual void Verify() { 917 virtual void Verify() {
918 } 918 }
919 }; 919 };
920 TEST_F(ExtensionPrefsSetExtensionControlledPref, 920 TEST_F(ExtensionPrefsSetExtensionControlledPref,
921 ExtensionPrefsSetExtensionControlledPref) {} 921 ExtensionPrefsSetExtensionControlledPref) {}
OLDNEW
« no previous file with comments | « chrome/browser/extensions/extension_info_map_unittest.cc ('k') | chrome/browser/extensions/extension_service.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698