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

Side by Side Diff: chrome/browser/extensions/api/declarative/rules_registry_service_unittest.cc

Issue 10500016: Move test_browser_thread.h from content\test to content\public\test. This way we can enforce that i… (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 8 years, 6 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/extensions/api/declarative/rules_registry_service.h" 5 #include "chrome/browser/extensions/api/declarative/rules_registry_service.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/message_loop.h" 8 #include "base/message_loop.h"
9 #include "chrome/browser/extensions/api/declarative/test_rules_registry.h" 9 #include "chrome/browser/extensions/api/declarative/test_rules_registry.h"
10 #include "content/test/test_browser_thread.h" 10 #include "content/public/test/test_browser_thread.h"
11 #include "testing/gtest/include/gtest/gtest.h" 11 #include "testing/gtest/include/gtest/gtest.h"
12 12
13 namespace { 13 namespace {
14 const char kExtensionId[] = "foo"; 14 const char kExtensionId[] = "foo";
15 15
16 void InsertRule(scoped_refptr<extensions::RulesRegistry> registry, 16 void InsertRule(scoped_refptr<extensions::RulesRegistry> registry,
17 const std::string& id) { 17 const std::string& id) {
18 std::vector<linked_ptr<extensions::RulesRegistry::Rule> > add_rules; 18 std::vector<linked_ptr<extensions::RulesRegistry::Rule> > add_rules;
19 add_rules.push_back(make_linked_ptr(new extensions::RulesRegistry::Rule)); 19 add_rules.push_back(make_linked_ptr(new extensions::RulesRegistry::Rule));
20 add_rules[0]->id.reset(new std::string(id)); 20 add_rules[0]->id.reset(new std::string(id));
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after
102 102
103 content::BrowserThread::PostTask( 103 content::BrowserThread::PostTask(
104 content::BrowserThread::IO, FROM_HERE, 104 content::BrowserThread::IO, FROM_HERE,
105 base::Bind(&VerifyNumberOfRules, 105 base::Bind(&VerifyNumberOfRules,
106 registry_service.GetRulesRegistry("io"), 0)); 106 registry_service.GetRulesRegistry("io"), 0));
107 107
108 message_loop.RunAllPending(); 108 message_loop.RunAllPending();
109 } 109 }
110 110
111 } // namespace extensions 111 } // namespace extensions
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698