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

Side by Side Diff: chromeos/network/network_sms_handler_unittest.cc

Issue 11887008: Deprecate ShillNetworkClient and add GeolocationHandler (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Fix unittest Created 7 years, 11 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 "chromeos/network/network_sms_handler.h" 5 #include "chromeos/network/network_sms_handler.h"
6 6
7 #include <set> 7 #include <set>
8 #include <string> 8 #include <string>
9 9
10 #include "base/command_line.h" 10 #include "base/command_line.h"
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
58 // Initialize DBusThreadManager with a stub implementation. 58 // Initialize DBusThreadManager with a stub implementation.
59 DBusThreadManager::InitializeWithStub(); 59 DBusThreadManager::InitializeWithStub();
60 ShillManagerClient::TestInterface* manager_test = 60 ShillManagerClient::TestInterface* manager_test =
61 DBusThreadManager::Get()->GetShillManagerClient()->GetTestInterface(); 61 DBusThreadManager::Get()->GetShillManagerClient()->GetTestInterface();
62 ASSERT_TRUE(manager_test); 62 ASSERT_TRUE(manager_test);
63 manager_test->AddDevice("stub_cellular_device2"); 63 manager_test->AddDevice("stub_cellular_device2");
64 ShillDeviceClient::TestInterface* device_test = 64 ShillDeviceClient::TestInterface* device_test =
65 DBusThreadManager::Get()->GetShillDeviceClient()->GetTestInterface(); 65 DBusThreadManager::Get()->GetShillDeviceClient()->GetTestInterface();
66 ASSERT_TRUE(device_test); 66 ASSERT_TRUE(device_test);
67 device_test->AddDevice("stub_cellular_device2", flimflam::kTypeCellular, 67 device_test->AddDevice("stub_cellular_device2", flimflam::kTypeCellular,
68 "/org/freedesktop/ModemManager1/stub/0", ":stub.0"); 68 "/org/freedesktop/ModemManager1/stub/0");
69 } 69 }
70 70
71 virtual void TearDown() OVERRIDE { 71 virtual void TearDown() OVERRIDE {
72 DBusThreadManager::Shutdown(); 72 DBusThreadManager::Shutdown();
73 } 73 }
74 74
75 protected: 75 protected:
76 MessageLoopForUI message_loop_; 76 MessageLoopForUI message_loop_;
77 }; 77 };
78 78
(...skipping 24 matching lines...) Expand all
103 103
104 // Test for messages delivered by signals. 104 // Test for messages delivered by signals.
105 test_observer->ClearMessages(); 105 test_observer->ClearMessages();
106 sms_handler->RequestUpdate(); 106 sms_handler->RequestUpdate();
107 message_loop_.RunUntilIdle(); 107 message_loop_.RunUntilIdle();
108 EXPECT_GE(test_observer->message_count(), 1); 108 EXPECT_GE(test_observer->message_count(), 1);
109 EXPECT_NE(messages.find(kMessage1), messages.end()); 109 EXPECT_NE(messages.find(kMessage1), messages.end());
110 } 110 }
111 111
112 } // namespace chromeos 112 } // namespace chromeos
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698