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

Side by Side Diff: sync/js/js_test_util.cc

Issue 134443004: sync: Remove some WebUI debug functions (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Rebase Created 6 years, 11 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 | « sync/js/js_test_util.h ('k') | sync/syncable/directory.h » ('j') | 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 "sync/js/js_test_util.h" 5 #include "sync/js/js_test_util.h"
6 6
7 #include "base/basictypes.h" 7 #include "base/basictypes.h"
8 #include "base/memory/scoped_ptr.h" 8 #include "base/memory/scoped_ptr.h"
9 #include "sync/js/js_arg_list.h" 9 #include "sync/js/js_arg_list.h"
10 #include "sync/js/js_event_details.h" 10 #include "sync/js/js_event_details.h"
(...skipping 69 matching lines...) Expand 10 before | Expand all | Expand 10 after
80 80
81 DISALLOW_COPY_AND_ASSIGN(HasDetailsMatcher); 81 DISALLOW_COPY_AND_ASSIGN(HasDetailsMatcher);
82 }; 82 };
83 83
84 } // namespace 84 } // namespace
85 85
86 ::testing::Matcher<const JsArgList&> HasArgs(const JsArgList& expected_args) { 86 ::testing::Matcher<const JsArgList&> HasArgs(const JsArgList& expected_args) {
87 return ::testing::MakeMatcher(new HasArgsMatcher(expected_args)); 87 return ::testing::MakeMatcher(new HasArgsMatcher(expected_args));
88 } 88 }
89 89
90 ::testing::Matcher<const JsArgList&> HasArgsAsList(
91 const base::ListValue& expected_args) {
92 scoped_ptr<base::ListValue> expected_args_copy(expected_args.DeepCopy());
93 return HasArgs(JsArgList(expected_args_copy.get()));
94 }
95
96 ::testing::Matcher<const JsEventDetails&> HasDetails( 90 ::testing::Matcher<const JsEventDetails&> HasDetails(
97 const JsEventDetails& expected_details) { 91 const JsEventDetails& expected_details) {
98 return ::testing::MakeMatcher(new HasDetailsMatcher(expected_details)); 92 return ::testing::MakeMatcher(new HasDetailsMatcher(expected_details));
99 } 93 }
100 94
101 ::testing::Matcher<const JsEventDetails&> HasDetailsAsDictionary( 95 ::testing::Matcher<const JsEventDetails&> HasDetailsAsDictionary(
102 const base::DictionaryValue& expected_details) { 96 const base::DictionaryValue& expected_details) {
103 scoped_ptr<base::DictionaryValue> expected_details_copy( 97 scoped_ptr<base::DictionaryValue> expected_details_copy(
104 expected_details.DeepCopy()); 98 expected_details.DeepCopy());
105 return HasDetails(JsEventDetails(expected_details_copy.get())); 99 return HasDetails(JsEventDetails(expected_details_copy.get()));
(...skipping 22 matching lines...) Expand all
128 MockJsReplyHandler::MockJsReplyHandler() {} 122 MockJsReplyHandler::MockJsReplyHandler() {}
129 123
130 MockJsReplyHandler::~MockJsReplyHandler() {} 124 MockJsReplyHandler::~MockJsReplyHandler() {}
131 125
132 WeakHandle<JsReplyHandler> MockJsReplyHandler::AsWeakHandle() { 126 WeakHandle<JsReplyHandler> MockJsReplyHandler::AsWeakHandle() {
133 return MakeWeakHandle(AsWeakPtr()); 127 return MakeWeakHandle(AsWeakPtr());
134 } 128 }
135 129
136 } // namespace syncer 130 } // namespace syncer
137 131
OLDNEW
« no previous file with comments | « sync/js/js_test_util.h ('k') | sync/syncable/directory.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698