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

Side by Side Diff: url/mojo/url_gurl_struct_traits_unittest.cc

Issue 2589663003: mojo:: Rename mojo::GetProxy() to mojo::MakeRequest() (Closed)
Patch Set: Rebase Created 3 years, 12 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 | « ui/views/mus/input_method_mus.cc ('k') | 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 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 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 <utility> 5 #include <utility>
6 6
7 #include "base/logging.h" 7 #include "base/logging.h"
8 #include "base/macros.h" 8 #include "base/macros.h"
9 #include "base/message_loop/message_loop.h" 9 #include "base/message_loop/message_loop.h"
10 #include "mojo/public/cpp/bindings/binding.h" 10 #include "mojo/public/cpp/bindings/binding.h"
(...skipping 20 matching lines...) Expand all
31 31
32 private: 32 private:
33 mojo::Binding<UrlTest> binding_; 33 mojo::Binding<UrlTest> binding_;
34 }; 34 };
35 35
36 // Mojo version of chrome IPC test in url/ipc/url_param_traits_unittest.cc. 36 // Mojo version of chrome IPC test in url/ipc/url_param_traits_unittest.cc.
37 TEST(MojoGURLStructTraitsTest, Basic) { 37 TEST(MojoGURLStructTraitsTest, Basic) {
38 base::MessageLoop message_loop; 38 base::MessageLoop message_loop;
39 39
40 mojom::UrlTestPtr proxy; 40 mojom::UrlTestPtr proxy;
41 UrlTestImpl impl(GetProxy(&proxy)); 41 UrlTestImpl impl(MakeRequest(&proxy));
42 42
43 const char* serialize_cases[] = { 43 const char* serialize_cases[] = {
44 "http://www.google.com/", 44 "http://www.google.com/",
45 "http://user:pass@host.com:888/foo;bar?baz#nop", 45 "http://user:pass@host.com:888/foo;bar?baz#nop",
46 }; 46 };
47 47
48 for (size_t i = 0; i < arraysize(serialize_cases); i++) { 48 for (size_t i = 0; i < arraysize(serialize_cases); i++) {
49 GURL input(serialize_cases[i]); 49 GURL input(serialize_cases[i]);
50 GURL output; 50 GURL output;
51 EXPECT_TRUE(proxy->BounceUrl(input, &output)); 51 EXPECT_TRUE(proxy->BounceUrl(input, &output));
(...skipping 29 matching lines...) Expand all
81 EXPECT_TRUE(proxy->BounceOrigin(non_unique, &output)); 81 EXPECT_TRUE(proxy->BounceOrigin(non_unique, &output));
82 EXPECT_EQ(non_unique, output); 82 EXPECT_EQ(non_unique, output);
83 EXPECT_FALSE(non_unique.unique()); 83 EXPECT_FALSE(non_unique.unique());
84 84
85 Origin unique; 85 Origin unique;
86 EXPECT_TRUE(proxy->BounceOrigin(unique, &output)); 86 EXPECT_TRUE(proxy->BounceOrigin(unique, &output));
87 EXPECT_TRUE(output.unique()); 87 EXPECT_TRUE(output.unique());
88 } 88 }
89 89
90 } // namespace url 90 } // namespace url
OLDNEW
« no previous file with comments | « ui/views/mus/input_method_mus.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698