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

Side by Side Diff: chrome/test/ui/ui_test.cc

Issue 10829007: Revert 148281 - Remove details from BROWSER_CLOSING and BROWSER_CLOSED notifications. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 5 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
« no previous file with comments | « chrome/common/chrome_notification_types.h ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
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 "chrome/test/ui/ui_test.h" 5 #include "chrome/test/ui/ui_test.h"
6 6
7 #if defined(OS_POSIX) 7 #if defined(OS_POSIX)
8 #include <signal.h> 8 #include <signal.h>
9 #include <sys/types.h> 9 #include <sys/types.h>
10 #endif 10 #endif
(...skipping 395 matching lines...) Expand 10 before | Expand all | Expand 10 after
406 406
407 bool UITestBase::CloseBrowser(BrowserProxy* browser, 407 bool UITestBase::CloseBrowser(BrowserProxy* browser,
408 bool* application_closed) const { 408 bool* application_closed) const {
409 DCHECK(application_closed); 409 DCHECK(application_closed);
410 if (!browser->is_valid() || !browser->handle()) 410 if (!browser->is_valid() || !browser->handle())
411 return false; 411 return false;
412 412
413 bool result = true; 413 bool result = true;
414 414
415 bool succeeded = automation()->Send(new AutomationMsg_CloseBrowser( 415 bool succeeded = automation()->Send(new AutomationMsg_CloseBrowser(
416 browser->handle(), &result)); 416 browser->handle(), &result, application_closed));
417 417
418 if (!succeeded) 418 if (!succeeded)
419 return false; 419 return false;
420 420
421 if (*application_closed) { 421 if (*application_closed) {
422 int exit_code = -1; 422 int exit_code = -1;
423 EXPECT_TRUE(launcher_->WaitForBrowserProcessToQuit( 423 EXPECT_TRUE(launcher_->WaitForBrowserProcessToQuit(
424 TestTimeouts::action_max_timeout(), &exit_code)); 424 TestTimeouts::action_max_timeout(), &exit_code));
425 EXPECT_EQ(0, exit_code); // Expect a clean shutown. 425 EXPECT_EQ(0, exit_code); // Expect a clean shutown.
426 } 426 }
(...skipping 306 matching lines...) Expand 10 before | Expand all | Expand 10 after
733 &session_end_completed)); 733 &session_end_completed));
734 ASSERT_TRUE(session_end_completed); 734 ASSERT_TRUE(session_end_completed);
735 735
736 // Make sure session restore says we didn't crash. 736 // Make sure session restore says we didn't crash.
737 scoped_ptr<DictionaryValue> profile_prefs(GetDefaultProfilePreferences()); 737 scoped_ptr<DictionaryValue> profile_prefs(GetDefaultProfilePreferences());
738 ASSERT_TRUE(profile_prefs.get()); 738 ASSERT_TRUE(profile_prefs.get());
739 ASSERT_TRUE(profile_prefs->GetBoolean(prefs::kSessionExitedCleanly, 739 ASSERT_TRUE(profile_prefs->GetBoolean(prefs::kSessionExitedCleanly,
740 &exited_cleanly)); 740 &exited_cleanly));
741 ASSERT_TRUE(exited_cleanly); 741 ASSERT_TRUE(exited_cleanly);
742 } 742 }
OLDNEW
« no previous file with comments | « chrome/common/chrome_notification_types.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698