summaryrefslogtreecommitdiffstats
path: root/googlemock/scripts/generator/cpp/gmock_class_test.py
diff options
context:
space:
mode:
authorplatisd <platisd@users.noreply.github.com>2021-02-05 19:35:02 +0100
committerplatisd <platisd@users.noreply.github.com>2021-02-05 21:30:10 +0100
commit46b188577b9478215d8cf8ea2bde5e4946844f1f (patch)
tree9441b25e1b650395dd97d5d49d5ce1993a1eca08 /googlemock/scripts/generator/cpp/gmock_class_test.py
parentf3ef7e173fd0853069f16c4b5afc7e80a350604b (diff)
downloadgoogletest-46b188577b9478215d8cf8ea2bde5e4946844f1f.tar.gz
googletest-46b188577b9478215d8cf8ea2bde5e4946844f1f.zip
Do not include void into mocked method arguments
If a function that takes no arguments explicitly states (void) then do not include it in the mocked method argument list since it triggers static assertions that expect no arguments to be present. Fixes (?) #3261
Diffstat (limited to 'googlemock/scripts/generator/cpp/gmock_class_test.py')
-rwxr-xr-xgooglemock/scripts/generator/cpp/gmock_class_test.py2
1 files changed, 1 insertions, 1 deletions
diff --git a/googlemock/scripts/generator/cpp/gmock_class_test.py b/googlemock/scripts/generator/cpp/gmock_class_test.py
index 7d5e2f17..eff475f4 100755
--- a/googlemock/scripts/generator/cpp/gmock_class_test.py
+++ b/googlemock/scripts/generator/cpp/gmock_class_test.py
@@ -156,7 +156,7 @@ class Foo {
};
"""
self.assertEqualIgnoreLeadingWhitespace(
- 'MOCK_METHOD(int, Bar, (void), (override));',
+ 'MOCK_METHOD(int, Bar, (), (override));',
self.GenerateMethodSource(source))
def testStrangeNewlineInParameter(self):
OpenPOWER on IntegriCloud