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

Side by Side Diff: webkit/glue/web_intent_service_data_unittest.cc

Issue 10690036: Fix compile errors on gcc 4.6. (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src/
Patch Set: Created 8 years, 5 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 | Annotate | Revision Log
« no previous file with comments | « no previous file | no next file » | 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 <string> 5 #include <string>
6 6
7 #include "base/utf_string_conversions.h" 7 #include "base/utf_string_conversions.h"
8 #include "googleurl/src/gurl.h" 8 #include "googleurl/src/gurl.h"
9 #include "testing/gtest/include/gtest/gtest.h" 9 #include "testing/gtest/include/gtest/gtest.h"
10 #include "webkit/glue/web_intent_service_data.h" 10 #include "webkit/glue/web_intent_service_data.h"
(...skipping 24 matching lines...) Expand all
35 EXPECT_EQ(string16(), intent.action); 35 EXPECT_EQ(string16(), intent.action);
36 EXPECT_EQ(string16(), intent.type); 36 EXPECT_EQ(string16(), intent.type);
37 EXPECT_EQ(string16(), intent.scheme); 37 EXPECT_EQ(string16(), intent.scheme);
38 EXPECT_EQ(string16(), intent.title); 38 EXPECT_EQ(string16(), intent.title);
39 EXPECT_EQ(WebIntentServiceData::DISPOSITION_WINDOW, intent.disposition); 39 EXPECT_EQ(WebIntentServiceData::DISPOSITION_WINDOW, intent.disposition);
40 } 40 }
41 41
42 TEST(WebIntentServiceDataTest, ActionServicesEqual) { 42 TEST(WebIntentServiceDataTest, ActionServicesEqual) {
43 43
44 // with default disposition... 44 // with default disposition...
45 WebIntentServiceData intent = WebIntentServiceData::WebIntentServiceData( 45 WebIntentServiceData intent(
46 ASCIIToUTF16("http://webintents.org/share"), 46 ASCIIToUTF16("http://webintents.org/share"),
47 ASCIIToUTF16("image/png"), 47 ASCIIToUTF16("image/png"),
48 string16(), 48 string16(),
49 GURL("http://abc.com/xyx.html"), 49 GURL("http://abc.com/xyx.html"),
50 ASCIIToUTF16("Image Sharing Service")); 50 ASCIIToUTF16("Image Sharing Service"));
51 51
52 Expect( 52 Expect(
53 "http://webintents.org/share", 53 "http://webintents.org/share",
54 "image/png", 54 "image/png",
55 std::string(), 55 std::string(),
56 "http://abc.com/xyx.html", 56 "http://abc.com/xyx.html",
57 "Image Sharing Service", 57 "Image Sharing Service",
58 WebIntentServiceData::DISPOSITION_WINDOW, 58 WebIntentServiceData::DISPOSITION_WINDOW,
59 &intent); 59 &intent);
60 } 60 }
61 61
62 TEST(WebIntentServiceDataTest, SchemeServicesEqual) { 62 TEST(WebIntentServiceDataTest, SchemeServicesEqual) {
63 63
64 // with default disposition... 64 // with default disposition...
65 WebIntentServiceData intent = WebIntentServiceData::WebIntentServiceData( 65 WebIntentServiceData intent(
66 string16(), 66 string16(),
67 string16(), 67 string16(),
68 ASCIIToUTF16("mailto"), 68 ASCIIToUTF16("mailto"),
69 GURL("http://abc.com/xyx.html"), 69 GURL("http://abc.com/xyx.html"),
70 ASCIIToUTF16("Image Sharing Service")); 70 ASCIIToUTF16("Image Sharing Service"));
71 71
72 Expect( 72 Expect(
73 "", 73 "",
74 "", 74 "",
75 "mailto", 75 "mailto",
76 "http://abc.com/xyx.html", 76 "http://abc.com/xyx.html",
77 "Image Sharing Service", 77 "Image Sharing Service",
78 WebIntentServiceData::DISPOSITION_WINDOW, 78 WebIntentServiceData::DISPOSITION_WINDOW,
79 &intent); 79 &intent);
80 } 80 }
81 81
82 } // namespace 82 } // namespace
OLDNEW
« 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