| Index: tools/clang/rewrite_to_chrome_style/tests/gmock-expected.cc
|
| diff --git a/tools/clang/rewrite_to_chrome_style/tests/gmock-expected.cc b/tools/clang/rewrite_to_chrome_style/tests/gmock-expected.cc
|
| new file mode 100644
|
| index 0000000000000000000000000000000000000000..e9f1b046753e4904f437adaafc1eededc8e850fe
|
| --- /dev/null
|
| +++ b/tools/clang/rewrite_to_chrome_style/tests/gmock-expected.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 mocked_interface;
|
| + EXPECT_CALL(mocked_interface, MyMethod(1));
|
| + EXPECT_CALL(
|
| + mocked_interface, // A comment to prevent reformatting into single line.
|
| + MyMethod(1));
|
| + mocked_interface.MyMethod(123);
|
| +}
|
| +
|
| +} // namespace blink
|
|
|