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

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

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/internal_api/sync_manager_impl_unittest.cc ('k') | sync/js/js_test_util.cc » ('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 #ifndef SYNC_JS_JS_TEST_UTIL_H_ 5 #ifndef SYNC_JS_JS_TEST_UTIL_H_
6 #define SYNC_JS_JS_TEST_UTIL_H_ 6 #define SYNC_JS_JS_TEST_UTIL_H_
7 7
8 #include <ostream> 8 #include <ostream>
9 #include <string> 9 #include <string>
10 10
(...skipping 17 matching lines...) Expand all
28 28
29 // Defined for googletest. Equivalent to "*os << args.ToString()". 29 // Defined for googletest. Equivalent to "*os << args.ToString()".
30 void PrintTo(const JsArgList& args, ::std::ostream* os); 30 void PrintTo(const JsArgList& args, ::std::ostream* os);
31 void PrintTo(const JsEventDetails& details, ::std::ostream* os); 31 void PrintTo(const JsEventDetails& details, ::std::ostream* os);
32 32
33 // A gmock matcher for JsArgList. Use like: 33 // A gmock matcher for JsArgList. Use like:
34 // 34 //
35 // EXPECT_CALL(mock, HandleJsReply("foo", HasArgs(expected_args))); 35 // EXPECT_CALL(mock, HandleJsReply("foo", HasArgs(expected_args)));
36 ::testing::Matcher<const JsArgList&> HasArgs(const JsArgList& expected_args); 36 ::testing::Matcher<const JsArgList&> HasArgs(const JsArgList& expected_args);
37 37
38 // Like HasArgs() but takes a ListValue instead.
39 ::testing::Matcher<const JsArgList&> HasArgsAsList(
40 const base::ListValue& expected_args);
41
42 // A gmock matcher for JsEventDetails. Use like: 38 // A gmock matcher for JsEventDetails. Use like:
43 // 39 //
44 // EXPECT_CALL(mock, HandleJsEvent("foo", HasArgs(expected_details))); 40 // EXPECT_CALL(mock, HandleJsEvent("foo", HasArgs(expected_details)));
45 ::testing::Matcher<const JsEventDetails&> HasDetails( 41 ::testing::Matcher<const JsEventDetails&> HasDetails(
46 const JsEventDetails& expected_details); 42 const JsEventDetails& expected_details);
47 43
48 // Like HasDetails() but takes a DictionaryValue instead. 44 // Like HasDetails() but takes a DictionaryValue instead.
49 ::testing::Matcher<const JsEventDetails&> HasDetailsAsDictionary( 45 ::testing::Matcher<const JsEventDetails&> HasDetailsAsDictionary(
50 const base::DictionaryValue& expected_details); 46 const base::DictionaryValue& expected_details);
51 47
(...skipping 47 matching lines...) Expand 10 before | Expand all | Expand 10 after
99 95
100 WeakHandle<JsReplyHandler> AsWeakHandle(); 96 WeakHandle<JsReplyHandler> AsWeakHandle();
101 97
102 MOCK_METHOD2(HandleJsReply, 98 MOCK_METHOD2(HandleJsReply,
103 void(const ::std::string&, const JsArgList&)); 99 void(const ::std::string&, const JsArgList&));
104 }; 100 };
105 101
106 } // namespace syncer 102 } // namespace syncer
107 103
108 #endif // SYNC_JS_JS_TEST_UTIL_H_ 104 #endif // SYNC_JS_JS_TEST_UTIL_H_
OLDNEW
« no previous file with comments | « sync/internal_api/sync_manager_impl_unittest.cc ('k') | sync/js/js_test_util.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698