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

Unified Diff: tools/clang/rewrite_to_chrome_style/tests/gmock-original.cc

Issue 2609473002: Renaming blink method names inside gmock's EXPECT_CALL macro invocation. (Closed)
Patch Set: Make SourceFileCallbacks's constructor explicit. Created 3 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 side-by-side diff with in-line comments
Download patch
« no previous file with comments | « tools/clang/rewrite_to_chrome_style/tests/gmock-expected.cc ('k') | tools/clang/scripts/run_tool.py » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/clang/rewrite_to_chrome_style/tests/gmock-original.cc
diff --git a/tools/clang/rewrite_to_chrome_style/tests/gmock-original.cc b/tools/clang/rewrite_to_chrome_style/tests/gmock-original.cc
new file mode 100644
index 0000000000000000000000000000000000000000..102bf1a46f30ed1660b242c51d37a27018e5e105
--- /dev/null
+++ b/tools/clang/rewrite_to_chrome_style/tests/gmock-original.cc
@@ -0,0 +1,28 @@
+// Copyright 2016 The Chromium Authors. All rights reserved.
+// Use of this source code is governed by a BSD-style license that can be
+// found in the LICENSE file.
+
+#include "gmock/gmock.h"
+
+namespace blink {
+
+class Interface {
+ public:
+ virtual void myMethod(int my_param) {}
+};
+
+class MockedInterface : public Interface {
+ public:
+ MOCK_METHOD1(myMethod, void(int));
+};
+
+void test() {
+ MockedInterface mockedInterface;
+ EXPECT_CALL(mockedInterface, myMethod(1));
+ EXPECT_CALL(
+ mockedInterface, // A comment to prevent reformatting into single line.
+ myMethod(1));
+ mockedInterface.myMethod(123);
+}
+
+} // namespace blink
« no previous file with comments | « tools/clang/rewrite_to_chrome_style/tests/gmock-expected.cc ('k') | tools/clang/scripts/run_tool.py » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698