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

Unified Diff: webkit/glue/cpp_bound_class_unittest.cc

Issue 10947005: Set user agent in cpp bindings test (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: updates Created 8 years, 3 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
« no previous file with comments | « no previous file | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: webkit/glue/cpp_bound_class_unittest.cc
diff --git a/webkit/glue/cpp_bound_class_unittest.cc b/webkit/glue/cpp_bound_class_unittest.cc
index e8d146602d4640485fd0a4343b33b5ea41d96035..8937e2d6ab7d37794803f9029a1502fac9186668 100644
--- a/webkit/glue/cpp_bound_class_unittest.cc
+++ b/webkit/glue/cpp_bound_class_unittest.cc
@@ -27,6 +27,8 @@
#include "third_party/WebKit/Source/WebKit/chromium/public/platform/WebURL.h"
#include "webkit/glue/cpp_binding_example.h"
#include "webkit/glue/webkit_glue.h"
+#include "webkit/user_agent/user_agent.h"
+#include "webkit/user_agent/user_agent_util.h"
using WebKit::WebFrame;
using WebKit::WebView;
@@ -93,6 +95,8 @@ class CppBoundClassTest : public testing::Test, public WebKit::WebFrameClient {
webview_->settings()->setJavaScriptEnabled(true);
webview_->initializeMainFrame(&webframe_client_);
webframe_client_.set_fallback_method_enabled(useFallback());
+ webkit_glue::SetUserAgent(webkit_glue::BuildUserAgentFromProduct(
+ "TestShell/0.0.0.0"), false);
WebKit::WebURLRequest urlRequest;
urlRequest.initialize();
« no previous file with comments | « no previous file | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698