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

Side by Side Diff: chrome/browser/extensions/api/socket/socket_api_unittest.cc

Issue 10907151: Extensions Docs Server: Enum values do not show up if enum is a type (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 8 years, 2 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 "base/values.h" 5 #include "base/values.h"
6 #include "chrome/browser/browser_process_impl.h" 6 #include "chrome/browser/browser_process_impl.h"
7 #include "chrome/browser/extensions/api/socket/socket_api.h" 7 #include "chrome/browser/extensions/api/socket/socket_api.h"
8 #include "chrome/browser/extensions/extension_function_test_utils.h" 8 #include "chrome/browser/extensions/extension_function_test_utils.h"
9 #include "chrome/browser/extensions/test_extension_system.h" 9 #include "chrome/browser/extensions/test_extension_system.h"
10 #include "chrome/browser/profiles/profile_manager.h" 10 #include "chrome/browser/profiles/profile_manager.h"
(...skipping 56 matching lines...) Expand 10 before | Expand all | Expand 10 after
67 TEST_F(SocketUnitTest, Create) { 67 TEST_F(SocketUnitTest, Create) {
68 // TODO(miket): enable this test. This will require teaching 68 // TODO(miket): enable this test. This will require teaching
69 // SocketCreateFunction to do its work on a thread other than IO. Getting 69 // SocketCreateFunction to do its work on a thread other than IO. Getting
70 // this CL landed was hard enough already, so we're going to save this work 70 // this CL landed was hard enough already, so we're going to save this work
71 // for another day. 71 // for another day.
72 if (false) { 72 if (false) {
73 scoped_ptr<base::DictionaryValue> result(RunFunctionAndReturnDict( 73 scoped_ptr<base::DictionaryValue> result(RunFunctionAndReturnDict(
74 new SocketCreateFunction(), "[\"tcp\"]")); 74 new SocketCreateFunction(), "[\"tcp\"]"));
75 ASSERT_TRUE(result.get()); 75 ASSERT_TRUE(result.get());
76 } 76 }
77 {
78 std::string error = RunFunctionAndReturnError(
79 new SocketCreateFunction(), "[\"nonexistent-socket-type\"]");
80 ASSERT_FALSE(error.empty()) << "Expected error. Got nothing instead.";
81 }
82 } 77 }
83 78
84 } // namespace extensions 79 } // namespace extensions
OLDNEW
« no previous file with comments | « chrome/browser/extensions/api/socket/socket_api.cc ('k') | chrome/browser/extensions/api/socket/socket_apitest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698