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 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_MOCK_URL_FETCHERS_H_ | 5 #ifndef CHROME_BROWSER_CHROMEOS_LOGIN_MOCK_URL_FETCHERS_H_ |
6 #define CHROME_BROWSER_CHROMEOS_LOGIN_MOCK_URL_FETCHERS_H_ | 6 #define CHROME_BROWSER_CHROMEOS_LOGIN_MOCK_URL_FETCHERS_H_ |
7 #pragma once | 7 #pragma once |
8 | 8 |
9 #include <string> | 9 #include <string> |
10 | 10 |
11 #include "base/message_loop.h" | 11 #include "base/message_loop.h" |
12 #include "base/task.h" | 12 #include "base/task.h" |
13 #include "chrome/common/net/url_fetcher.h" | 13 #include "content/common/url_fetcher.h" |
14 #include "googleurl/src/gurl.h" | 14 #include "googleurl/src/gurl.h" |
15 #include "net/url_request/url_request_status.h" | 15 #include "net/url_request/url_request_status.h" |
16 | 16 |
17 namespace chromeos { | 17 namespace chromeos { |
18 | 18 |
19 // Simulates a URL fetch by posting a delayed task. This fetch expects to be | 19 // Simulates a URL fetch by posting a delayed task. This fetch expects to be |
20 // canceled, and fails the test if it is not | 20 // canceled, and fails the test if it is not |
21 class ExpectCanceledFetcher : public URLFetcher { | 21 class ExpectCanceledFetcher : public URLFetcher { |
22 public: | 22 public: |
23 ExpectCanceledFetcher(bool success, | 23 ExpectCanceledFetcher(bool success, |
(...skipping 101 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
125 | 125 |
126 private: | 126 private: |
127 GURL url_; | 127 GURL url_; |
128 | 128 |
129 DISALLOW_COPY_AND_ASSIGN(HostedFetcher); | 129 DISALLOW_COPY_AND_ASSIGN(HostedFetcher); |
130 }; | 130 }; |
131 | 131 |
132 } // namespace chromeos | 132 } // namespace chromeos |
133 | 133 |
134 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_MOCK_URL_FETCHERS_H_ | 134 #endif // CHROME_BROWSER_CHROMEOS_LOGIN_MOCK_URL_FETCHERS_H_ |
OLD | NEW |