OLD | NEW |
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_webrequest/webrequest_action
.h" | 5 #include "chrome/browser/extensions/api/declarative_webrequest/webrequest_action
.h" |
6 | 6 |
7 #include "base/files/file_path.h" | 7 #include "base/files/file_path.h" |
8 #include "base/json/json_file_value_serializer.h" | 8 #include "base/json/json_file_value_serializer.h" |
9 #include "base/memory/ref_counted.h" | 9 #include "base/memory/ref_counted.h" |
10 #include "base/memory/scoped_ptr.h" | 10 #include "base/memory/scoped_ptr.h" |
(...skipping 81 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
92 | 92 |
93 net::TestURLRequestContext context_; | 93 net::TestURLRequestContext context_; |
94 | 94 |
95 // An extension with *.com host permissions and the DWR permission. | 95 // An extension with *.com host permissions and the DWR permission. |
96 scoped_refptr<Extension> extension_; | 96 scoped_refptr<Extension> extension_; |
97 // An extension with host permissions for all URLs and the DWR permission. | 97 // An extension with host permissions for all URLs and the DWR permission. |
98 scoped_refptr<Extension> extension_all_urls_; | 98 scoped_refptr<Extension> extension_all_urls_; |
99 scoped_refptr<ExtensionInfoMap> extension_info_map_; | 99 scoped_refptr<ExtensionInfoMap> extension_info_map_; |
100 | 100 |
101 private: | 101 private: |
102 MessageLoopForIO message_loop_; | 102 base::MessageLoopForIO message_loop_; |
103 content::TestBrowserThread io_thread_; | 103 content::TestBrowserThread io_thread_; |
104 }; | 104 }; |
105 | 105 |
106 void WebRequestActionWithThreadsTest::SetUp() { | 106 void WebRequestActionWithThreadsTest::SetUp() { |
107 testing::Test::SetUp(); | 107 testing::Test::SetUp(); |
108 | 108 |
109 std::string error; | 109 std::string error; |
110 extension_ = LoadManifestUnchecked("permissions", | 110 extension_ = LoadManifestUnchecked("permissions", |
111 "web_request_com_host_permissions.json", | 111 "web_request_com_host_permissions.json", |
112 Manifest::INVALID_LOCATION, | 112 Manifest::INVALID_LOCATION, |
(...skipping 454 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
567 for (WebRequestActionSet::Actions::const_iterator it = | 567 for (WebRequestActionSet::Actions::const_iterator it = |
568 action_set->actions().begin(); | 568 action_set->actions().begin(); |
569 it != action_set->actions().end(); | 569 it != action_set->actions().end(); |
570 ++it) { | 570 ++it) { |
571 EXPECT_EQ(kExpectedNames[index], (*it)->GetName()); | 571 EXPECT_EQ(kExpectedNames[index], (*it)->GetName()); |
572 ++index; | 572 ++index; |
573 } | 573 } |
574 } | 574 } |
575 | 575 |
576 } // namespace extensions | 576 } // namespace extensions |
OLD | NEW |