[
https://issues.apache.org/jira/browse/MESOS-3486?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15146764#comment-15146764
]
Michael Browning commented on MESOS-3486:
-----------------------------------------
I'm not sure it makes sense to use FUTURE_PROTOBUF instead of FUTURE_MESSAGE in
the test suite -- FUTURE_PROTOBUF's return type is that of its first argument,
where FUTURE_MESSAGE returns process::Message. A typical case (from
tests/cram_md5_authentication_tests.cpp) is:
Future<Message> message =
FUTURE_MESSAGE(Eq(AuthenticateMessage().GetTypeName()), _, _);
If we replace this with the following (instantiation of Eq removed, since that
occurs inside FutureProtobuf already):
Future<Message> message = FUTURE_PROTOBUF(AuthenticateMessage(), _, _);
We're actually getting an AuthenticateMessage back, which isn't at all related
to process::Message (it's a subclass of the protoc Message class). Needless to
say, this doesn't work when later statements in the test expect a
process::Message to be living in that Future instance. I think all instances of
FUTURE_MESSAGE should remain as is.
> Use DROP_PROTOBUF instead of DROP_MESSAGE in tests
> --------------------------------------------------
>
> Key: MESOS-3486
> URL: https://issues.apache.org/jira/browse/MESOS-3486
> Project: Mesos
> Issue Type: Improvement
> Reporter: Neil Conway
> Assignee: Michael Browning
> Priority: Trivial
> Labels: mesosphere, newbie, tests
>
> The tests use DROP_MESSAGE(), DROP_MESSAGES(), and FUTURE_MESSAGE() in
> various places where it would be more clear and concise to use
> DROP_PROTOBUF(), DROP_PROTOBUFS(), and FUTURE_PROTOBUF() instead.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)