| OLD | NEW |
| 1 // Copyright (c) 2011 The Chromium Authors. All rights reserved. | 1 // Copyright (c) 2011 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/bind.h" | 5 #include "base/bind.h" |
| 6 #include "base/bind_helpers.h" | 6 #include "base/bind_helpers.h" |
| 7 #include "base/string_util.h" | 7 #include "base/string_util.h" |
| 8 #include "base/utf_string_conversions.h" | 8 #include "base/utf_string_conversions.h" |
| 9 #include "chrome/browser/geolocation/chrome_access_token_store.h" | 9 #include "chrome/browser/geolocation/chrome_access_token_store.h" |
| 10 #include "chrome/test/base/in_process_browser_test.h" | 10 #include "chrome/test/base/in_process_browser_test.h" |
| 11 #include "chrome/test/base/ui_test_utils.h" | 11 #include "chrome/test/base/ui_test_utils.h" |
| 12 #include "content/test/test_browser_thread.h" | 12 #include "content/test/test_browser_thread.h" |
| 13 #include "content/public/browser/access_token_store.h" |
| 13 | 14 |
| 15 using content::AccessTokenStore; |
| 14 using content::BrowserThread; | 16 using content::BrowserThread; |
| 15 | 17 |
| 16 namespace { | 18 namespace { |
| 17 | 19 |
| 18 // The token store factory implementation expects to be used from any well-known | 20 // The token store factory implementation expects to be used from any well-known |
| 19 // chrome thread other than UI. We could use any arbitrary thread; IO is | 21 // chrome thread other than UI. We could use any arbitrary thread; IO is |
| 20 // a good choice as this is the expected usage. | 22 // a good choice as this is the expected usage. |
| 21 const BrowserThread::ID kExpectedClientThreadId = BrowserThread::IO; | 23 const BrowserThread::ID kExpectedClientThreadId = BrowserThread::IO; |
| 22 const char* kRefServerUrl1 = "https://test.domain.example/foo?id=bar.bar"; | 24 const char* kRefServerUrl1 = "https://test.domain.example/foo?id=bar.bar"; |
| 23 const char* kRefServerUrl2 = "http://another.domain.example/foo?id=bar.bar#2"; | 25 const char* kRefServerUrl2 = "http://another.domain.example/foo?id=bar.bar#2"; |
| (...skipping 102 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 126 // Set a token for the old default network provider url. | 128 // Set a token for the old default network provider url. |
| 127 DoTestStepAndWaitForResults(kOldDefaultNetworkProviderUrl, | 129 DoTestStepAndWaitForResults(kOldDefaultNetworkProviderUrl, |
| 128 NULL, &ref_token1); | 130 NULL, &ref_token1); |
| 129 // Check that the token related to the old default network provider url | 131 // Check that the token related to the old default network provider url |
| 130 // was deleted. | 132 // was deleted. |
| 131 DoTestStepAndWaitForResults(kOldDefaultNetworkProviderUrl, | 133 DoTestStepAndWaitForResults(kOldDefaultNetworkProviderUrl, |
| 132 NULL, NULL); | 134 NULL, NULL); |
| 133 } | 135 } |
| 134 | 136 |
| 135 } // namespace | 137 } // namespace |
| OLD | NEW |