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

Side by Side Diff: chrome/browser/extensions/extension_ui_unittest.cc

Issue 11413050: chrome/browser: Update calls from RunAllPending() to RunUntilIdle(). (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 1 month 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 "base/command_line.h" 5 #include "base/command_line.h"
6 #include "base/json/json_file_value_serializer.h" 6 #include "base/json/json_file_value_serializer.h"
7 #include "base/message_loop.h" 7 #include "base/message_loop.h"
8 #include "base/path_service.h" 8 #include "base/path_service.h"
9 #include "base/string_util.h" 9 #include "base/string_util.h"
10 #include "chrome/browser/extensions/extension_service.h" 10 #include "chrome/browser/extensions/extension_service.h"
(...skipping 27 matching lines...) Expand all
38 management_policy_ = system->management_policy(); 38 management_policy_ = system->management_policy();
39 39
40 handler_.reset(new ExtensionSettingsHandler(extension_service_, 40 handler_.reset(new ExtensionSettingsHandler(extension_service_,
41 management_policy_)); 41 management_policy_));
42 } 42 }
43 43
44 virtual void TearDown() OVERRIDE { 44 virtual void TearDown() OVERRIDE {
45 handler_.reset(); 45 handler_.reset();
46 profile_.reset(); 46 profile_.reset();
47 // Execute any pending deletion tasks. 47 // Execute any pending deletion tasks.
48 message_loop_.RunAllPending(); 48 message_loop_.RunUntilIdle();
49 } 49 }
50 50
51 static DictionaryValue* DeserializeJSONTestData(const FilePath& path, 51 static DictionaryValue* DeserializeJSONTestData(const FilePath& path,
52 std::string *error) { 52 std::string *error) {
53 Value* value; 53 Value* value;
54 54
55 JSONFileValueSerializer serializer(path); 55 JSONFileValueSerializer serializer(path);
56 value = serializer.Deserialize(NULL, error); 56 value = serializer.Deserialize(NULL, error);
57 57
58 return static_cast<DictionaryValue*>(value); 58 return static_cast<DictionaryValue*>(value);
(...skipping 206 matching lines...) Expand 10 before | Expand all | Expand 10 after
265 265
266 scoped_ptr<DictionaryValue> extension_details( 266 scoped_ptr<DictionaryValue> extension_details(
267 CreateExtensionDetailViewFromPath( 267 CreateExtensionDetailViewFromPath(
268 extension_path, pages, Extension::LOAD)); 268 extension_path, pages, Extension::LOAD));
269 269
270 FilePath::StringType ui_path; 270 FilePath::StringType ui_path;
271 271
272 EXPECT_TRUE(extension_details->GetString("path", &ui_path)); 272 EXPECT_TRUE(extension_details->GetString("path", &ui_path));
273 EXPECT_EQ(extension_path, FilePath(ui_path)); 273 EXPECT_EQ(extension_path, FilePath(ui_path));
274 } 274 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698