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

Side by Side Diff: chrome/browser/predictors/autocomplete_action_predictor_unittest.cc

Issue 136683004: Removes MessageLoop::TYPE_XXX where possible (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: resolve merge Created 6 years, 11 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
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/browser/predictors/autocomplete_action_predictor.h" 5 #include "chrome/browser/predictors/autocomplete_action_predictor.h"
6 6
7 #include "base/auto_reset.h" 7 #include "base/auto_reset.h"
8 #include "base/command_line.h" 8 #include "base/command_line.h"
9 #include "base/guid.h" 9 #include "base/guid.h"
10 #include "base/memory/ref_counted.h" 10 #include "base/memory/ref_counted.h"
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
76 AutocompleteActionPredictor::ACTION_NONE } 76 AutocompleteActionPredictor::ACTION_NONE }
77 }; 77 };
78 78
79 } // end namespace 79 } // end namespace
80 80
81 namespace predictors { 81 namespace predictors {
82 82
83 class AutocompleteActionPredictorTest : public testing::Test { 83 class AutocompleteActionPredictorTest : public testing::Test {
84 public: 84 public:
85 AutocompleteActionPredictorTest() 85 AutocompleteActionPredictorTest()
86 : loop_(base::MessageLoop::TYPE_DEFAULT), 86 : ui_thread_(BrowserThread::UI, &loop_),
87 ui_thread_(BrowserThread::UI, &loop_),
88 db_thread_(BrowserThread::DB, &loop_), 87 db_thread_(BrowserThread::DB, &loop_),
89 file_thread_(BrowserThread::FILE, &loop_), 88 file_thread_(BrowserThread::FILE, &loop_),
90 profile_(new TestingProfile()), 89 profile_(new TestingProfile()),
91 predictor_(new AutocompleteActionPredictor(profile_.get())) { 90 predictor_(new AutocompleteActionPredictor(profile_.get())) {
92 } 91 }
93 92
94 virtual ~AutocompleteActionPredictorTest() { 93 virtual ~AutocompleteActionPredictorTest() {
95 predictor_.reset(NULL); 94 predictor_.reset(NULL);
96 profile_.reset(NULL); 95 profile_.reset(NULL);
97 loop_.RunUntilIdle(); 96 loop_.RunUntilIdle();
(...skipping 278 matching lines...) Expand 10 before | Expand all | Expand 10 after
376 AutocompleteActionPredictor::ACTION_PRERENDER) ? 375 AutocompleteActionPredictor::ACTION_PRERENDER) ?
377 AutocompleteActionPredictor::ACTION_PRECONNECT : 376 AutocompleteActionPredictor::ACTION_PRECONNECT :
378 test_url_db[i].expected_action; 377 test_url_db[i].expected_action;
379 EXPECT_EQ(expected_action, 378 EXPECT_EQ(expected_action,
380 predictor()->RecommendAction(test_url_db[i].user_text, match)) 379 predictor()->RecommendAction(test_url_db[i].user_text, match))
381 << "Unexpected action for " << match.destination_url; 380 << "Unexpected action for " << match.destination_url;
382 } 381 }
383 } 382 }
384 383
385 } // namespace predictors 384 } // namespace predictors
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698