| OLD | NEW |
| 1 // Copyright 2016 The Chromium Authors. All rights reserved. | 1 // Copyright 2016 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/strings/utf_string_conversions.h" | 5 #include "base/strings/utf_string_conversions.h" |
| 6 #include "chrome/browser/extensions/api/tabs/tabs_api.h" | 6 #include "chrome/browser/extensions/api/tabs/tabs_api.h" |
| 7 #include "chrome/browser/extensions/extension_function_test_utils.h" | 7 #include "chrome/browser/extensions/extension_function_test_utils.h" |
| 8 #include "chrome/browser/extensions/extension_service_test_base.h" | 8 #include "chrome/browser/extensions/extension_service_test_base.h" |
| 9 #include "chrome/browser/extensions/extension_tab_util.h" | 9 #include "chrome/browser/extensions/extension_tab_util.h" |
| 10 #include "chrome/browser/ui/browser.h" | 10 #include "chrome/browser/ui/browser.h" |
| (...skipping 183 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 194 ASSERT_TRUE(tabs_list_with_permission->GetDictionary(1, &third_tab_info)); | 194 ASSERT_TRUE(tabs_list_with_permission->GetDictionary(1, &third_tab_info)); |
| 195 | 195 |
| 196 std::vector<int> expected_tabs_ids; | 196 std::vector<int> expected_tabs_ids; |
| 197 expected_tabs_ids.push_back( | 197 expected_tabs_ids.push_back( |
| 198 ExtensionTabUtil::GetTabId(web_contentses[0].get())); | 198 ExtensionTabUtil::GetTabId(web_contentses[0].get())); |
| 199 expected_tabs_ids.push_back( | 199 expected_tabs_ids.push_back( |
| 200 ExtensionTabUtil::GetTabId(web_contentses[2].get())); | 200 ExtensionTabUtil::GetTabId(web_contentses[2].get())); |
| 201 | 201 |
| 202 int first_tab_id = -1; | 202 int first_tab_id = -1; |
| 203 ASSERT_TRUE(first_tab_info->GetInteger("id", &first_tab_id)); | 203 ASSERT_TRUE(first_tab_info->GetInteger("id", &first_tab_id)); |
| 204 EXPECT_TRUE(ContainsValue(expected_tabs_ids, first_tab_id)); | 204 EXPECT_TRUE(base::ContainsValue(expected_tabs_ids, first_tab_id)); |
| 205 | 205 |
| 206 int third_tab_id = -1; | 206 int third_tab_id = -1; |
| 207 ASSERT_TRUE(third_tab_info->GetInteger("id", &third_tab_id)); | 207 ASSERT_TRUE(third_tab_info->GetInteger("id", &third_tab_id)); |
| 208 EXPECT_TRUE(ContainsValue(expected_tabs_ids, third_tab_id)); | 208 EXPECT_TRUE(base::ContainsValue(expected_tabs_ids, third_tab_id)); |
| 209 } | 209 } |
| 210 } | 210 } |
| 211 | 211 |
| 212 } // namespace extensions | 212 } // namespace extensions |
| OLD | NEW |