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

Side by Side Diff: content/browser/intents/internal_web_intents_dispatcher_unittest.cc

Issue 10377180: Fix uninitialized member in ctor. (Closed) Base URL: http://git.chromium.org/chromium/src.git@master
Patch Set: Fix review nit. Created 8 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 unified diff | Download patch
« no previous file with comments | « no previous file | webkit/glue/web_intent_reply_data.h » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright (c) 2012 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2012 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 #include "base/bind.h" 5 #include "base/bind.h"
6 #include "base/utf_string_conversions.h" 6 #include "base/utf_string_conversions.h"
7 #include "content/browser/intents/intent_injector.h" 7 #include "content/browser/intents/intent_injector.h"
8 #include "content/browser/intents/internal_web_intents_dispatcher.h" 8 #include "content/browser/intents/internal_web_intents_dispatcher.h"
9 #include "content/browser/renderer_host/test_render_view_host.h" 9 #include "content/browser/renderer_host/test_render_view_host.h"
10 #include "content/browser/web_contents/test_web_contents.h" 10 #include "content/browser/web_contents/test_web_contents.h"
11 #include "webkit/glue/web_intent_data.h" 11 #include "webkit/glue/web_intent_data.h"
12 #include "webkit/glue/web_intent_reply_data.h" 12 #include "webkit/glue/web_intent_reply_data.h"
13 13
14 class InternalWebIntentsDispatcherTest 14 class InternalWebIntentsDispatcherTest
15 : public content::RenderViewHostTestHarness { 15 : public content::RenderViewHostTestHarness {
16 public: 16 public:
17 InternalWebIntentsDispatcherTest() { 17 InternalWebIntentsDispatcherTest()
18 replied_ = 0; 18 : replied_(0),
19 notified_reply_type_(webkit_glue::WEB_INTENT_REPLY_INVALID) {
19 } 20 }
20 21
21 ~InternalWebIntentsDispatcherTest() {} 22 ~InternalWebIntentsDispatcherTest() {}
22 23
23 void NotifyReply(webkit_glue::WebIntentReplyType reply_type, 24 void NotifyReply(webkit_glue::WebIntentReplyType reply_type,
24 const string16& data) { 25 const string16& data) {
25 notified_reply_type_ = reply_type; 26 notified_reply_type_ = reply_type;
26 notified_data_ = data; 27 notified_data_ = data;
27 } 28 }
28 29
(...skipping 37 matching lines...) Expand 10 before | Expand all | Expand 10 after
66 intent, base::Bind(&InternalWebIntentsDispatcherTest::NotifyReply, 67 intent, base::Bind(&InternalWebIntentsDispatcherTest::NotifyReply,
67 base::Unretained(this))); 68 base::Unretained(this)));
68 dispatcher->DispatchIntent(web_contents()); 69 dispatcher->DispatchIntent(web_contents());
69 EXPECT_FALSE(dispatcher->intent_injector_ == NULL); 70 EXPECT_FALSE(dispatcher->intent_injector_ == NULL);
70 dispatcher->ResetDispatch(); 71 dispatcher->ResetDispatch();
71 EXPECT_TRUE(dispatcher->intent_injector_ == NULL); 72 EXPECT_TRUE(dispatcher->intent_injector_ == NULL);
72 73
73 dispatcher->SendReplyMessage(webkit_glue::WEB_INTENT_REPLY_SUCCESS, 74 dispatcher->SendReplyMessage(webkit_glue::WEB_INTENT_REPLY_SUCCESS,
74 ASCIIToUTF16("success")); 75 ASCIIToUTF16("success"));
75 } 76 }
OLDNEW
« no previous file with comments | « no previous file | webkit/glue/web_intent_reply_data.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698