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

Unified Diff: net/url_request/url_request_throttler_test_support.h

Issue 1148603003: Remove X-Chrome-Exponential-Throttling header (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Comments Created 5 years, 7 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 side-by-side diff with in-line comments
Download patch
Index: net/url_request/url_request_throttler_test_support.h
diff --git a/net/url_request/url_request_throttler_test_support.h b/net/url_request/url_request_throttler_test_support.h
index 9331c4b6218045b609ea6faa24e7022f160b5c72..93e4e2a39baaee17734dad9c025b6e8ceae4efce 100644
--- a/net/url_request/url_request_throttler_test_support.h
+++ b/net/url_request/url_request_throttler_test_support.h
@@ -11,7 +11,6 @@
#include "base/time/tick_clock.h"
#include "base/time/time.h"
#include "net/base/backoff_entry.h"
-#include "net/url_request/url_request_throttler_header_interface.h"
namespace net {
@@ -29,35 +28,6 @@ class TestTickClock : public base::TickClock {
DISALLOW_COPY_AND_ASSIGN(TestTickClock);
};
-// Mocks the URLRequestThrottlerHeaderInterface, allowing testing code to
-// pass arbitrary fake headers to the throttling code.
-class MockURLRequestThrottlerHeaderAdapter
- : public URLRequestThrottlerHeaderInterface {
- public:
- // Constructs mock response headers with the given |response_code| and no
- // custom response header fields.
- explicit MockURLRequestThrottlerHeaderAdapter(int response_code);
-
- // Constructs mock response headers with the given |response_code| and
- // with a custom-retry header value |retry_value| if it is non-empty, and
- // a custom opt-out header value |opt_out_value| if it is non-empty.
- MockURLRequestThrottlerHeaderAdapter(const std::string& retry_value,
- const std::string& opt_out_value,
- int response_code);
- ~MockURLRequestThrottlerHeaderAdapter() override;
-
- // URLRequestThrottlerHeaderInterface overrides.
- std::string GetNormalizedValue(const std::string& key) const override;
- int GetResponseCode() const override;
-
- private:
- std::string fake_retry_value_;
- std::string fake_opt_out_value_;
- int fake_response_code_;
-
- DISALLOW_COPY_AND_ASSIGN(MockURLRequestThrottlerHeaderAdapter);
-};
-
} // namespace net
#endif // NET_URL_REQUEST_URL_REQUEST_THROTTLER_TEST_SUPPORT_H_
« no previous file with comments | « net/url_request/url_request_throttler_simulation_unittest.cc ('k') | net/url_request/url_request_throttler_test_support.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698