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

Side by Side Diff: content/browser/speech/speech_recognition_request_unittest.cc

Issue 7006005: Move UrlFetcher to content. I originally thought that it's only used by chrome code, but turns o... (Closed) Base URL: svn://chrome-svn/chrome/trunk/src/
Patch Set: fix linux Created 9 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) 2011 The Chromium Authors. All rights reserved. 1 // Copyright (c) 2011 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/utf_string_conversions.h" 5 #include "base/utf_string_conversions.h"
6 #include "chrome/common/net/test_url_fetcher_factory.h"
7 #include "content/browser/speech/speech_recognition_request.h" 6 #include "content/browser/speech/speech_recognition_request.h"
7 #include "content/common/test_url_fetcher_factory.h"
8 #include "net/url_request/url_request_context_getter.h" 8 #include "net/url_request/url_request_context_getter.h"
9 #include "net/url_request/url_request_status.h" 9 #include "net/url_request/url_request_status.h"
10 #include "testing/gtest/include/gtest/gtest.h" 10 #include "testing/gtest/include/gtest/gtest.h"
11 11
12 namespace speech_input { 12 namespace speech_input {
13 13
14 class SpeechRecognitionRequestTest : public SpeechRecognitionRequestDelegate, 14 class SpeechRecognitionRequestTest : public SpeechRecognitionRequestDelegate,
15 public testing::Test { 15 public testing::Test {
16 public: 16 public:
17 SpeechRecognitionRequestTest() : error_(false) { } 17 SpeechRecognitionRequestTest() : error_(false) { }
(...skipping 72 matching lines...) Expand 10 before | Expand all | Expand 10 after
90 EXPECT_TRUE(error_); 90 EXPECT_TRUE(error_);
91 EXPECT_EQ(0U, result_.size()); 91 EXPECT_EQ(0U, result_.size());
92 92
93 // Malformed JSON case. 93 // Malformed JSON case.
94 CreateAndTestRequest(true, "{\"hypotheses\":[{\"unknownkey\":\"hello\"}]}"); 94 CreateAndTestRequest(true, "{\"hypotheses\":[{\"unknownkey\":\"hello\"}]}");
95 EXPECT_TRUE(error_); 95 EXPECT_TRUE(error_);
96 EXPECT_EQ(0U, result_.size()); 96 EXPECT_EQ(0U, result_.size());
97 } 97 }
98 98
99 } // namespace speech_input 99 } // namespace speech_input
OLDNEW
« no previous file with comments | « content/browser/speech/speech_recognition_request.h ('k') | content/browser/speech/speech_recognizer_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698