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

Issue 319083003: Use the same fake User-Agent string as GetContentShell()->GetUserAgent() for URLRequestContext in c… (Closed)

Created:
6 years, 6 months ago by tyoshino (SeeGerritForStatus)
Modified:
6 years, 6 months ago
Reviewers:
Adam Rice, jam
CC:
chromium-reviews, darin-cc_chromium.org, jam, jochen+watch_chromium.org
Visibility:
Public.

Description

Use the same fake User-Agent string as GetContentShell()->GetUserAgent() for URLRequestContext in content_shell ShellContentClient::GetUserAgent() returns a fake User-Agent. It's used for navigator.userAgent, loading layout test test case file, etc. But ShellURLRequestContextGetter has an HttpUserAgentSettings with an empty string for User-Agent. Factor out the code to build the fake User-Agent from ShellContentClient::GetUserAgent() into GetShellUserAgent() and use it for ShellURLRequestContextGetter. This is almost the same as how ChromeShellContentClient and ChromeURLRequestContextGetter are doing. With this, we can test that WebSocket handshake request contains the correct user-agent header value. BUG=347109 Committed: https://src.chromium.org/viewvc/chrome?view=rev&revision=275673

Patch Set 1 #

Unified diffs Side-by-side diffs Delta from patch set Stats (+13 lines, -5 lines) Patch
M content/shell/browser/shell_url_request_context_getter.cc View 2 chunks +3 lines, -1 line 0 comments Download
M content/shell/common/shell_content_client.h View 1 chunk +2 lines, -0 lines 0 comments Download
M content/shell/common/shell_content_client.cc View 2 chunks +8 lines, -4 lines 0 comments Download

Messages

Total messages: 7 (0 generated)
tyoshino (SeeGerritForStatus)
6 years, 6 months ago (2014-06-06 03:45:15 UTC) #1
Adam Rice
lgtm
6 years, 6 months ago (2014-06-06 05:58:11 UTC) #2
tyoshino (SeeGerritForStatus)
+jam for OWNER review
6 years, 6 months ago (2014-06-06 06:00:44 UTC) #3
jam
lgtm
6 years, 6 months ago (2014-06-06 14:44:17 UTC) #4
tyoshino (SeeGerritForStatus)
The CQ bit was checked by tyoshino@chromium.org
6 years, 6 months ago (2014-06-06 22:47:30 UTC) #5
commit-bot: I haz the power
CQ is trying da patch. Follow status at https://chromium-status.appspot.com/cq/tyoshino@chromium.org/319083003/1
6 years, 6 months ago (2014-06-06 22:50:06 UTC) #6
commit-bot: I haz the power
6 years, 6 months ago (2014-06-07 09:46:21 UTC) #7
Message was sent while issue was closed.
Change committed as 275673

Powered by Google App Engine
This is Rietveld 408576698