Reputation: 2785
I am using gmock in CLion, whenever I format my file, all the MOCK_METHOD macros are broken up with unnecessary line breaks. like this:
Before:
class MockObservableExecutor : public IObservableExecutor {
MOCK_METHOD1(registerExecutor, void(IObserverExecutor*));
MOCK_METHOD2(sendMessage, void(const std::string&, const std::string&));
};
After:
class MockObservableExecutor : public IObservableExecutor {
MOCK_METHOD1(registerExecutor, void(IObserverExecutor
*));
MOCK_METHOD2(sendMessage, void(
const std::string&, const std::string&));
};
I see no reason that the single asterisk should get a line of its own, how can I tell CLion to stop its shenanigans? Why does it decide that it should break the line there?
For now I have added //@formatter:off
and //@formatter:on
statemenst around my mock but I do want formatting to work for some of the stuff in my mock.
Upvotes: 1
Views: 169