diff options
Diffstat (limited to 'scripts/generator/cpp/gmock_class_test.py')
-rwxr-xr-x | scripts/generator/cpp/gmock_class_test.py | 30 |
1 files changed, 30 insertions, 0 deletions
diff --git a/scripts/generator/cpp/gmock_class_test.py b/scripts/generator/cpp/gmock_class_test.py index 361dad7f..ae3739af 100755 --- a/scripts/generator/cpp/gmock_class_test.py +++ b/scripts/generator/cpp/gmock_class_test.py @@ -219,6 +219,36 @@ class Foo { 'MOCK_METHOD0_T(Bar,\nint());', self.GenerateMethodSource(source)) + def testPointerArgWithoutNames(self): + source = """ +class Foo { + virtual int Bar(C*); +}; +""" + self.assertEqualIgnoreLeadingWhitespace( + 'MOCK_METHOD1(Bar,\nint(C*));', + self.GenerateMethodSource(source)) + + def testReferenceArgWithoutNames(self): + source = """ +class Foo { + virtual int Bar(C&); +}; +""" + self.assertEqualIgnoreLeadingWhitespace( + 'MOCK_METHOD1(Bar,\nint(C&));', + self.GenerateMethodSource(source)) + + def testArrayArgWithoutNames(self): + source = """ +class Foo { + virtual int Bar(C[]); +}; +""" + self.assertEqualIgnoreLeadingWhitespace( + 'MOCK_METHOD1(Bar,\nint(C[]));', + self.GenerateMethodSource(source)) + class GenerateMocksTest(TestCase): |