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

Side by Side Diff: chrome/browser/ui/panels/base_panel_browser_test.cc

Issue 10977048: Fix bug in disabling sync for default apps (Closed) Base URL: http://git.chromium.org/git/chromium.git@trunk
Patch Set: Fix browser and integration tests, which got broken Created 8 years, 2 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/browser/ui/panels/base_panel_browser_test.h" 5 #include "chrome/browser/ui/panels/base_panel_browser_test.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/memory/weak_ptr.h" 9 #include "base/memory/weak_ptr.h"
10 #include "base/message_loop.h" 10 #include "base/message_loop.h"
(...skipping 395 matching lines...) Expand 10 before | Expand all | Expand 10 after
406 scoped_ptr<DictionaryValue> input_value(extra_value.DeepCopy()); 406 scoped_ptr<DictionaryValue> input_value(extra_value.DeepCopy());
407 input_value->SetString(extension_manifest_keys::kVersion, "1.0.0.0"); 407 input_value->SetString(extension_manifest_keys::kVersion, "1.0.0.0");
408 input_value->SetString(extension_manifest_keys::kName, "Sample Extension"); 408 input_value->SetString(extension_manifest_keys::kName, "Sample Extension");
409 409
410 std::string error; 410 std::string error;
411 scoped_refptr<Extension> extension = Extension::Create( 411 scoped_refptr<Extension> extension = Extension::Create(
412 full_path, location, *input_value, Extension::NO_FLAGS, &error); 412 full_path, location, *input_value, Extension::NO_FLAGS, &error);
413 EXPECT_TRUE(extension.get()); 413 EXPECT_TRUE(extension.get());
414 EXPECT_STREQ("", error.c_str()); 414 EXPECT_STREQ("", error.c_str());
415 browser()->profile()->GetExtensionService()-> 415 browser()->profile()->GetExtensionService()->
416 OnExtensionInstalled(extension.get(), false /* not from webstore */, 416 OnExtensionInstalled(extension.get(), syncer::StringOrdinal(),
417 syncer::StringOrdinal(),
418 false /* no requirement errors */); 417 false /* no requirement errors */);
419 return extension; 418 return extension;
420 } 419 }
421 420
422 void BasePanelBrowserTest::SetTestingAreas(const gfx::Rect& primary_screen_area, 421 void BasePanelBrowserTest::SetTestingAreas(const gfx::Rect& primary_screen_area,
423 const gfx::Rect& work_area) { 422 const gfx::Rect& work_area) {
424 DCHECK(primary_screen_area.Contains(work_area)); 423 DCHECK(primary_screen_area.Contains(work_area));
425 mock_display_settings_provider_->SetPrimaryScreenArea(primary_screen_area); 424 mock_display_settings_provider_->SetPrimaryScreenArea(primary_screen_area);
426 mock_display_settings_provider_->SetWorkArea( 425 mock_display_settings_provider_->SetWorkArea(
427 work_area.IsEmpty() ? primary_screen_area : work_area); 426 work_area.IsEmpty() ? primary_screen_area : work_area);
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after
463 } 462 }
464 463
465 void BasePanelBrowserTest::MoveMouse(const gfx::Point& position) { 464 void BasePanelBrowserTest::MoveMouse(const gfx::Point& position) {
466 PanelManager::GetInstance()->mouse_watcher()->NotifyMouseMovement(position); 465 PanelManager::GetInstance()->mouse_watcher()->NotifyMouseMovement(position);
467 } 466 }
468 467
469 std::string BasePanelBrowserTest::MakePanelName(int index) { 468 std::string BasePanelBrowserTest::MakePanelName(int index) {
470 std::string panel_name("Panel"); 469 std::string panel_name("Panel");
471 return panel_name + base::IntToString(index); 470 return panel_name + base::IntToString(index);
472 } 471 }
OLDNEW
« no previous file with comments | « chrome/browser/sync/test/integration/sync_extension_helper.cc ('k') | chrome/common/extensions/extension.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698