This is an automatically generated e-mail. To reply, visit:

Review request for mesos, Ben Mahler, Isabel Jimenez, and Vinod Kone.

Bugs: MESOS-3339

Repository: mesos


Instead of introducing a `DROP_HTTP_EVENT` filtering abstraction, made the 
existing interface callback based that allows to use the already existing 
testing semantics. Also, the new interface allows us to use a generic interface 
across scheduler library versions.

This gets rid of the following hack:
// Enqueues all received events into a libprocess queue.
ACTION_P(Enqueue, queue)
  std::queue<Event> events = arg0;
  while (!events.empty()) {
    // Note that we currently drop HEARTBEATs because most of these tests
    // are not designed to deal with heartbeats.
    // TODO(vinod): Implement DROP_HTTP_CALLS that can filter heartbeats.
    if (events.front().type() == Event::HEARTBEAT) {
      VLOG(1) << "Ignoring HEARTBEAT event";
    } else {

New way ( similar to what we do for the driver implementation )
EXPECT_CALL(callbacks, heartbeat())
    .WillRepeatedly(Return()); // Ignore heartbeats.


  src/tests/mesos.hpp 3e58b454c75a2ab9f8b4a29785fa823afefd0c8a 
  src/tests/scheduler_tests.cpp 7946cb48d62f4ed6d0fdbc771746518e31921f97 

Diff: https://reviews.apache.org/r/39372/diff/


make check ( I only modified a couple of existing tests to show the new 
interface usage. If the interface looks good, would go ahead and modify all the 
tests )


Anand Mazumdar

Reply via email to