Index: chrome/browser/unload_uitest.cc |
=================================================================== |
--- chrome/browser/unload_uitest.cc (revision 13127) |
+++ chrome/browser/unload_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. |
@@ -78,7 +78,7 @@ |
int max_wait_time = 5000; |
while (max_wait_time > 0) { |
max_wait_time -= kCheckDelayMs; |
- Sleep(kCheckDelayMs); |
+ PlatformThread::Sleep(kCheckDelayMs); |
if (!IsBrowserRunning()) |
break; |
} |
@@ -89,7 +89,7 @@ |
int max_wait_time = 5000; |
while (max_wait_time > 0) { |
max_wait_time -= kCheckDelayMs; |
- Sleep(kCheckDelayMs); |
+ PlatformThread::Sleep(kCheckDelayMs); |
if (expected_title == GetActiveTabTitle()) |
break; |
} |
@@ -104,11 +104,9 @@ |
} |
void NavigateToNolistenersFileTwice() { |
- NavigateToURL( |
- URLRequestMockHTTPJob::GetMockUrl(L"title2.html")); |
+ NavigateToURL(URLRequestMockHTTPJob::GetMockUrl(L"title2.html")); |
CheckTitle(L"Title Of Awesomeness"); |
- NavigateToURL( |
- URLRequestMockHTTPJob::GetMockUrl(L"title2.html")); |
+ NavigateToURL(URLRequestMockHTTPJob::GetMockUrl(L"title2.html")); |
CheckTitle(L"Title Of Awesomeness"); |
} |
@@ -118,12 +116,10 @@ |
void NavigateToNolistenersFileTwiceAsync() { |
// TODO(ojan): We hit a DCHECK in RenderViewHost::OnMsgShouldCloseACK |
// if we don't sleep here. |
- Sleep(400); |
- NavigateToURLAsync( |
- URLRequestMockHTTPJob::GetMockUrl(L"title2.html")); |
- Sleep(400); |
- NavigateToURL( |
- URLRequestMockHTTPJob::GetMockUrl(L"title2.html")); |
+ PlatformThread::Sleep(400); |
+ NavigateToURLAsync(URLRequestMockHTTPJob::GetMockUrl(L"title2.html")); |
+ PlatformThread::Sleep(400); |
+ NavigateToURL(URLRequestMockHTTPJob::GetMockUrl(L"title2.html")); |
CheckTitle(L"Title Of Awesomeness"); |
} |