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

Unified Diff: headless/public/util/testing/generic_url_request_mocks.h

Issue 2937963003: Shift cookie system callbacks to OnceCallback to impedance match mojo. (Closed)
Patch Set: Finish Merge Created 3 years, 6 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: headless/public/util/testing/generic_url_request_mocks.h
diff --git a/headless/public/util/testing/generic_url_request_mocks.h b/headless/public/util/testing/generic_url_request_mocks.h
index 98f5e9d4b44c898b8ac9036b445b864c90311add..96b49651deb1c57d328633366e9f8a659287c8a0 100644
--- a/headless/public/util/testing/generic_url_request_mocks.h
+++ b/headless/public/util/testing/generic_url_request_mocks.h
@@ -58,7 +58,7 @@ class HEADLESS_EXPORT MockCookieStore : public net::CookieStore {
void SetCookieWithOptionsAsync(const GURL& url,
const std::string& cookie_line,
const net::CookieOptions& options,
- const SetCookiesCallback& callback) override;
+ SetCookiesCallback callback) override;
void SetCookieWithDetailsAsync(const GURL& url,
const std::string& name,
@@ -72,44 +72,43 @@ class HEADLESS_EXPORT MockCookieStore : public net::CookieStore {
bool http_only,
net::CookieSameSite same_site,
net::CookiePriority priority,
- const SetCookiesCallback& callback) override;
+ SetCookiesCallback callback) override;
void SetCanonicalCookieAsync(std::unique_ptr<net::CanonicalCookie> cookie,
bool secure_source,
bool modify_http_only,
- const SetCookiesCallback& callback) override;
+ SetCookiesCallback callback) override;
void GetCookiesWithOptionsAsync(const GURL& url,
const net::CookieOptions& options,
- const GetCookiesCallback& callback) override;
+ GetCookiesCallback callback) override;
- void GetCookieListWithOptionsAsync(
- const GURL& url,
- const net::CookieOptions& options,
- const GetCookieListCallback& callback) override;
+ void GetCookieListWithOptionsAsync(const GURL& url,
+ const net::CookieOptions& options,
+ GetCookieListCallback callback) override;
- void GetAllCookiesAsync(const GetCookieListCallback& callback) override;
+ void GetAllCookiesAsync(GetCookieListCallback callback) override;
void DeleteCookieAsync(const GURL& url,
const std::string& cookie_name,
- const base::Closure& callback) override;
+ base::OnceClosure callback) override;
void DeleteCanonicalCookieAsync(const net::CanonicalCookie& cookie,
- const DeleteCallback& callback) override;
+ DeleteCallback callback) override;
void DeleteAllCreatedBetweenAsync(const base::Time& delete_begin,
const base::Time& delete_end,
- const DeleteCallback& callback) override;
+ DeleteCallback callback) override;
void DeleteAllCreatedBetweenWithPredicateAsync(
const base::Time& delete_begin,
const base::Time& delete_end,
const CookiePredicate& predicate,
- const DeleteCallback& callback) override;
+ DeleteCallback callback) override;
- void DeleteSessionCookiesAsync(const DeleteCallback&) override;
+ void DeleteSessionCookiesAsync(DeleteCallback) override;
- void FlushStore(const base::Closure& callback) override;
+ void FlushStore(base::OnceClosure callback) override;
void SetForceKeepSessionState() override;
@@ -125,7 +124,7 @@ class HEADLESS_EXPORT MockCookieStore : public net::CookieStore {
private:
void SendCookies(const GURL& url,
const net::CookieOptions& options,
- const GetCookieListCallback& callback);
+ GetCookieListCallback callback);
net::CookieList cookies_;

Powered by Google App Engine
This is Rietveld 408576698