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

Side by Side Diff: chrome/browser/chromeos/usb_mount_observer_browsertest.cc

Issue 5734002: Continuation of CL 5685007, rename the singleton accessor method in more files. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: . Created 10 years 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) 2010 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2010 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/ref_counted.h" 5 #include "base/ref_counted.h"
6 #include "base/utf_string_conversions.h" 6 #include "base/utf_string_conversions.h"
7 #include "chrome/browser/browser_list.h" 7 #include "chrome/browser/browser_list.h"
8 #include "chrome/browser/chromeos/cros/mock_mount_library.h" 8 #include "chrome/browser/chromeos/cros/mock_mount_library.h"
9 #include "chrome/browser/chromeos/usb_mount_observer.h" 9 #include "chrome/browser/chromeos/usb_mount_observer.h"
10 #include "chrome/browser/dom_ui/mediaplayer_ui.h" 10 #include "chrome/browser/dom_ui/mediaplayer_ui.h"
(...skipping 24 matching lines...) Expand all
35 } 35 }
36 return false; 36 return false;
37 } 37 }
38 }; 38 };
39 39
40 IN_PROC_BROWSER_TEST_F(USBMountObserverBrowserTest, PopupOnEvent) { 40 IN_PROC_BROWSER_TEST_F(USBMountObserverBrowserTest, PopupOnEvent) {
41 StartHTTPServer(); 41 StartHTTPServer();
42 // Doing this so we have a valid profile 42 // Doing this so we have a valid profile
43 ui_test_utils::NavigateToURL(browser(), 43 ui_test_utils::NavigateToURL(browser(),
44 GURL(chrome::kChromeUIDownloadsURL)); 44 GURL(chrome::kChromeUIDownloadsURL));
45 chromeos::USBMountObserver* observe = chromeos::USBMountObserver::Get(); 45 chromeos::USBMountObserver* observe = chromeos::USBMountObserver::GetInstance( );
M-A Ruel 2010/12/13 15:54:02 80 cols
46 observe->set_profile(browser()->profile()); 46 observe->set_profile(browser()->profile());
47 scoped_ptr<chromeos::MockMountLibrary> lib(new chromeos::MockMountLibrary()); 47 scoped_ptr<chromeos::MockMountLibrary> lib(new chromeos::MockMountLibrary());
48 lib->AddObserver(observe); 48 lib->AddObserver(observe);
49 // Check that its not currently visible 49 // Check that its not currently visible
50 EXPECT_FALSE(IsFilebrowserVisible()); 50 EXPECT_FALSE(IsFilebrowserVisible());
51 51
52 lib->FireDeviceInsertEvents(); 52 lib->FireDeviceInsertEvents();
53 53
54 EXPECT_TRUE(IsFilebrowserVisible()); 54 EXPECT_TRUE(IsFilebrowserVisible());
55 } 55 }
56 56
57 } 57 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698