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

Unified Diff: remoting/test/chromoting_test_driver_environment_unittest.cc

Issue 2734543002: Adding 'Show Host List' option to CTD (Closed)
Patch Set: Addressing comments and fixing unit tests Created 3 years, 10 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « remoting/test/chromoting_test_driver_environment.cc ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: remoting/test/chromoting_test_driver_environment_unittest.cc
diff --git a/remoting/test/chromoting_test_driver_environment_unittest.cc b/remoting/test/chromoting_test_driver_environment_unittest.cc
index 843be6dd4e1a9297107fa826ce9cb1f3d31ef85c..63add746f0ef5e9af7ced658689e8b5526880a14 100644
--- a/remoting/test/chromoting_test_driver_environment_unittest.cc
+++ b/remoting/test/chromoting_test_driver_environment_unittest.cc
@@ -81,7 +81,8 @@ void ChromotingTestDriverEnvironmentTest::SetUp() {
}
bool ChromotingTestDriverEnvironmentTest::RefreshHostList() {
- return environment_object_->RefreshHostList();
+ return environment_object_->RefreshHostList() &&
+ environment_object_->FindHostInHostList();
}
HostInfo ChromotingTestDriverEnvironmentTest::CreateFakeHostInfo() {
@@ -113,9 +114,8 @@ TEST_F(ChromotingTestDriverEnvironmentTest, InitializeObjectWithAuthCode) {
kFakeAccessTokenFetcherAccessTokenValue);
EXPECT_EQ(environment_object_->host_list().size(), 0u);
- // Now Retrieve the host list.
- EXPECT_TRUE(environment_object_->WaitForHostOnline(kFakeHostJidValue,
- kFakeHostNameValue));
+ // Now retrieve the host list.
+ EXPECT_TRUE(environment_object_->WaitForHostOnline());
// Should only have one host in the list.
EXPECT_EQ(environment_object_->host_list().size(), kExpectedHostListSize);
@@ -152,9 +152,8 @@ TEST_F(ChromotingTestDriverEnvironmentTest, InitializeObjectWithRefreshToken) {
kFakeAccessTokenFetcherAccessTokenValue);
EXPECT_EQ(environment_object_->host_list().size(), 0u);
- // Now Retrieve the host list.
- EXPECT_TRUE(environment_object_->WaitForHostOnline(kFakeHostJidValue,
- kFakeHostNameValue));
+ // Now retrieve the host list.
+ EXPECT_TRUE(environment_object_->WaitForHostOnline());
// Should only have one host in the list.
EXPECT_EQ(environment_object_->host_list().size(), kExpectedHostListSize);
@@ -262,7 +261,7 @@ TEST_F(ChromotingTestDriverEnvironmentTest, RefreshHostList_HostOffline) {
environment_object_->SetHostNameForTest(kFakeHostNameValue);
environment_object_->SetHostJidForTest(kFakeHostJidValue);
- EXPECT_FALSE(RefreshHostList());
+ EXPECT_TRUE(RefreshHostList());
EXPECT_FALSE(environment_object_->host_info().IsReadyForConnection());
}
« no previous file with comments | « remoting/test/chromoting_test_driver_environment.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698