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

Side by Side Diff: chrome/installer/setup/setup_util_unittest.cc

Issue 57423008: Base: Make RegistryOverrideManager support sharded/parallel tests. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: run git cl format 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 (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/installer/setup/setup_util_unittest.h" 5 #include "chrome/installer/setup/setup_util_unittest.h"
6 6
7 #include <windows.h> 7 #include <windows.h>
8 8
9 #include <string> 9 #include <string>
10 10
(...skipping 392 matching lines...) Expand 10 before | Expand all | Expand 10 after
403 403
404 namespace { 404 namespace {
405 405
406 class MigrateMultiToSingleTest : public testing::Test { 406 class MigrateMultiToSingleTest : public testing::Test {
407 protected: 407 protected:
408 virtual void SetUp() OVERRIDE { 408 virtual void SetUp() OVERRIDE {
409 registry_override_manager_.OverrideRegistry(kRootKey, 409 registry_override_manager_.OverrideRegistry(kRootKey,
410 L"MigrateMultiToSingleTest"); 410 L"MigrateMultiToSingleTest");
411 } 411 }
412 412
413 virtual void TearDown() OVERRIDE {
414 registry_override_manager_.RemoveAllOverrides();
415 }
416
417 static const bool kSystemLevel = false; 413 static const bool kSystemLevel = false;
418 static const HKEY kRootKey; 414 static const HKEY kRootKey;
419 static const wchar_t kVersionString[]; 415 static const wchar_t kVersionString[];
420 static const wchar_t kMultiChannel[]; 416 static const wchar_t kMultiChannel[];
421 registry_util::RegistryOverrideManager registry_override_manager_; 417 registry_util::RegistryOverrideManager registry_override_manager_;
422 }; 418 };
423 419
424 const bool MigrateMultiToSingleTest::kSystemLevel; 420 const bool MigrateMultiToSingleTest::kSystemLevel;
425 const HKEY MigrateMultiToSingleTest::kRootKey = 421 const HKEY MigrateMultiToSingleTest::kRootKey =
426 kSystemLevel ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER; 422 kSystemLevel ? HKEY_LOCAL_MACHINE : HKEY_CURRENT_USER;
(...skipping 53 matching lines...) Expand 10 before | Expand all | Expand 10 after
480 BrowserDistribution::CHROME_FRAME)); 476 BrowserDistribution::CHROME_FRAME));
481 EXPECT_TRUE(chrome_frame.GetUsageStats(&usagestats)); 477 EXPECT_TRUE(chrome_frame.GetUsageStats(&usagestats));
482 EXPECT_EQ(1U, usagestats); 478 EXPECT_EQ(1U, usagestats);
483 EXPECT_EQ(L"2.0-dev", chrome_frame.channel().value()); 479 EXPECT_EQ(L"2.0-dev", chrome_frame.channel().value());
484 480
485 // Confirm that the binaries' channel no longer contains GCF. 481 // Confirm that the binaries' channel no longer contains GCF.
486 ASSERT_TRUE(binaries.Initialize(kSystemLevel, 482 ASSERT_TRUE(binaries.Initialize(kSystemLevel,
487 BrowserDistribution::CHROME_BINARIES)); 483 BrowserDistribution::CHROME_BINARIES));
488 EXPECT_EQ(L"2.0-dev-multi", binaries.channel().value()); 484 EXPECT_EQ(L"2.0-dev-multi", binaries.channel().value());
489 } 485 }
OLDNEW
« no previous file with comments | « chrome/installer/gcapi/gcapi_test_registry_overrider.cc ('k') | chrome/installer/util/product_state_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698