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

Side by Side Diff: chrome/browser/intents/cws_intents_registry_unittest.cc

Issue 10483003: Move the rest of the content\test headers that are used by embedders to content\public\test. This w… (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: Created 8 years, 6 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
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 "chrome/browser/intents/cws_intents_registry.h" 5 #include "chrome/browser/intents/cws_intents_registry.h"
6 6
7 #include "base/bind.h" 7 #include "base/bind.h"
8 #include "base/bind_helpers.h" 8 #include "base/bind_helpers.h"
9 #include "base/message_loop.h" 9 #include "base/message_loop.h"
10 #include "base/utf_string_conversions.h" 10 #include "base/utf_string_conversions.h"
11 #include "content/test/test_url_fetcher_factory.h" 11 #include "content/public/test/test_url_fetcher_factory.h"
12 #include "net/url_request/url_request_test_util.h" 12 #include "net/url_request/url_request_test_util.h"
13 #include "testing/gtest/include/gtest/gtest.h" 13 #include "testing/gtest/include/gtest/gtest.h"
14 14
15 namespace { 15 namespace {
16 16
17 const char kCWSResponseInvalid[] = 17 const char kCWSResponseInvalid[] =
18 "{\"error\":{" 18 "{\"error\":{"
19 "\"errors\":[{" 19 "\"errors\":[{"
20 "\"domain\":\"global\"," 20 "\"domain\":\"global\","
21 "\"reason\":\"invalid\"," 21 "\"reason\":\"invalid\","
(...skipping 128 matching lines...) Expand 10 before | Expand all | Expand 10 after
150 150
151 TEST_F(CWSIntentsRegistryTest, BuildQueryURL) { 151 TEST_F(CWSIntentsRegistryTest, BuildQueryURL) {
152 const std::string kExpectedURL = "https://www.googleapis.com" 152 const std::string kExpectedURL = "https://www.googleapis.com"
153 "/chromewebstore/v1.1b/items/intent" 153 "/chromewebstore/v1.1b/items/intent"
154 "?intent=action&mime_types=mime%2Ftype"; 154 "?intent=action&mime_types=mime%2Ftype";
155 GURL url = CWSIntentsRegistry::BuildQueryURL(ASCIIToUTF16("action"), 155 GURL url = CWSIntentsRegistry::BuildQueryURL(ASCIIToUTF16("action"),
156 ASCIIToUTF16("mime/type")); 156 ASCIIToUTF16("mime/type"));
157 157
158 EXPECT_EQ(kExpectedURL, url.spec().substr(0, kExpectedURL.size())); 158 EXPECT_EQ(kExpectedURL, url.spec().substr(0, kExpectedURL.size()));
159 } 159 }
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698