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

Side by Side Diff: chrome/browser/ui/cocoa/wrench_menu/wrench_menu_controller_unittest.mm

Issue 671653002: Standardize usage of virtual/override/final in chrome/browser/ui/ (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 6 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
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 "base/command_line.h" 5 #include "base/command_line.h"
6 #include "base/mac/scoped_nsobject.h" 6 #include "base/mac/scoped_nsobject.h"
7 #include "base/strings/sys_string_conversions.h" 7 #include "base/strings/sys_string_conversions.h"
8 #include "base/strings/utf_string_conversions.h" 8 #include "base/strings/utf_string_conversions.h"
9 #include "chrome/app/chrome_command_ids.h" 9 #include "chrome/app/chrome_command_ids.h"
10 #include "chrome/browser/sync/profile_sync_service_factory.h" 10 #include "chrome/browser/sync/profile_sync_service_factory.h"
(...skipping 32 matching lines...) Expand 10 before | Expand all | Expand 10 after
43 // seems that the vector of observers is getting hosed somewhere between 43 // seems that the vector of observers is getting hosed somewhere between
44 // |-[ToolbarController dealloc]| and ~MockWrenchMenuModel(). This line 44 // |-[ToolbarController dealloc]| and ~MockWrenchMenuModel(). This line
45 // short-circuits the parent destructor to avoid this crash. 45 // short-circuits the parent destructor to avoid this crash.
46 tab_strip_model_ = NULL; 46 tab_strip_model_ = NULL;
47 } 47 }
48 MOCK_METHOD2(ExecuteCommand, void(int command_id, int event_flags)); 48 MOCK_METHOD2(ExecuteCommand, void(int command_id, int event_flags));
49 }; 49 };
50 50
51 class DummyRouter : public browser_sync::LocalSessionEventRouter { 51 class DummyRouter : public browser_sync::LocalSessionEventRouter {
52 public: 52 public:
53 virtual ~DummyRouter() {} 53 ~DummyRouter() override {}
54 virtual void StartRoutingTo( 54 void StartRoutingTo(
55 browser_sync::LocalSessionEventHandler* handler) override {} 55 browser_sync::LocalSessionEventHandler* handler) override {}
56 virtual void Stop() override {} 56 void Stop() override {}
57 }; 57 };
58 58
59 class WrenchMenuControllerTest 59 class WrenchMenuControllerTest
60 : public CocoaProfileTest { 60 : public CocoaProfileTest {
61 public: 61 public:
62 WrenchMenuControllerTest() 62 WrenchMenuControllerTest()
63 : local_device_(new sync_driver::LocalDeviceInfoProviderMock( 63 : local_device_(new sync_driver::LocalDeviceInfoProviderMock(
64 "WrenchMenuControllerTest", 64 "WrenchMenuControllerTest",
65 "Test Machine", 65 "Test Machine",
66 "Chromium 10k", 66 "Chromium 10k",
(...skipping 165 matching lines...) Expand 10 before | Expand all | Expand 10 after
232 } 232 }
233 233
234 // Verify that |RecentTabsMenuModelDelegate| is deleted before the model 234 // Verify that |RecentTabsMenuModelDelegate| is deleted before the model
235 // it's observing. 235 // it's observing.
236 TEST_F(WrenchMenuControllerTest, RecentTabDeleteOrder) { 236 TEST_F(WrenchMenuControllerTest, RecentTabDeleteOrder) {
237 [controller_ menuNeedsUpdate:[controller_ menu]]; 237 [controller_ menuNeedsUpdate:[controller_ menu]];
238 // If the delete order is wrong then the test will crash on exit. 238 // If the delete order is wrong then the test will crash on exit.
239 } 239 }
240 240
241 } // namespace 241 } // namespace
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698