Index: chrome/test/automation/automation_proxy_uitest.cc |
=================================================================== |
--- chrome/test/automation/automation_proxy_uitest.cc (revision 13127) |
+++ chrome/test/automation/automation_proxy_uitest.cc (working copy) |
@@ -1,4 +1,4 @@ |
-// Copyright (c) 2006-2008 The Chromium Authors. All rights reserved. |
+// Copyright (c) 2006-2009 The Chromium Authors. All rights reserved. |
// Use of this source code is governed by a BSD-style license that can be |
// found in the LICENSE file. |
@@ -295,7 +295,7 @@ |
1, &is_timeout); |
ASSERT_TRUE(is_timeout); |
- Sleep(10); |
+ PlatformThread::Sleep(10); |
} |
// This test is disabled. See bug 794412. |
@@ -320,7 +320,7 @@ |
10000, &is_timeout); |
ASSERT_FALSE(is_timeout); |
- Sleep(10); |
+ PlatformThread::Sleep(10); |
} |
TEST_F(AutomationProxyTest, GoBackForward) { |
@@ -500,7 +500,7 @@ |
std::wstring title; |
int i; |
for (i = 0; i < 10; ++i) { |
- Sleep(sleep_timeout_ms()); |
+ PlatformThread::Sleep(sleep_timeout_ms()); |
ASSERT_TRUE(tab->GetTabTitle(&title)); |
if (title == L"Destinations" || title == L"New Tab") |
break; |
@@ -638,7 +638,7 @@ |
std::wstring title; |
int i; |
for (i = 0; i < 10; ++i) { |
- Sleep(sleep_timeout_ms()); |
+ PlatformThread::Sleep(sleep_timeout_ms()); |
ASSERT_TRUE(tab->GetTabTitle(&title)); |
if (title == L"Destinations") |
break; |
@@ -841,7 +841,7 @@ |
bool WaitForNavigationComplete(int max_time_to_wait_ms) { |
base::TimeTicks start(base::TimeTicks::Now()); |
while (!navigate_complete_) { |
- Sleep(50); |
+ PlatformThread::Sleep(50); |
MessageLoop::current()->RunAllPending(); |
base::TimeTicks end(base::TimeTicks::Now()); |
base::TimeDelta delta = end - start; |
@@ -894,7 +894,7 @@ |
tab->NavigateInExternalTab(GURL(L"http://www.google.com")); |
EXPECT_EQ(true, ExternalTabHandler(external_tab_container, 1000)); |
// Since the tab goes away lazily, wait a bit |
- Sleep(1000); |
+ PlatformThread::Sleep(1000); |
EXPECT_FALSE(tab->is_valid()); |
} |
} |
@@ -1107,7 +1107,7 @@ |
tab->NavigateToURL(net::FilePathToFileURL(filename)); |
// Allow some time for the popup to show up and close. |
- Sleep(2000); |
+ PlatformThread::Sleep(2000); |
std::wstring expected(L"string"); |
std::wstring jscript = CreateJSString(L"\"" + expected + L"\""); |