> On May 24, 2019, 2:54 p.m., Benjamin Mahler wrote: > > Thanks for adding this: > > > > (1) If we're going to introduce this, let's include a patch after it that > > updates all the `SUBSCRIBE` related tests in `src/tests/api_tests.cpp` to > > use this. > > (2) Can you also include some folks with context for the `SUBSCRIBE` code / > > tests in this review (and the one that updates `src/tests/api_tests.cpp`?) > > (3) It seems the code is prone to crashing if the object gets destructed, > > consider using a Process wrapper and dispatching. > > (4) How about placing this in a mocks/ folder?
Actually, since you have a master/ folder in the subsequent patch, consider placing these files in that folder. - Benjamin ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/70671/#review215497 ----------------------------------------------------------- On May 21, 2019, 1:54 p.m., Andrei Sekretenko wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/70671/ > ----------------------------------------------------------- > > (Updated May 21, 2019, 1:54 p.m.) > > > Review request for mesos and Benjamin Mahler. > > > Repository: mesos > > > Description > ------- > > This patch introduces a class with mock methods for subscribing to the > events of master's V1 streaming API and setting expectations for them. > > > Diffs > ----- > > src/Makefile.am 5f97523fbe2d80733fbdcc7706f2761f5a071f9f > src/tests/CMakeLists.txt e6b1d8a097246f0921467d7f778034d6754fcff6 > src/tests/mock_master_api_subscriber.hpp PRE-CREATION > src/tests/mock_master_api_subscriber.cpp PRE-CREATION > > > Diff: https://reviews.apache.org/r/70671/diff/2/ > > > Testing > ------- > > > Thanks, > > Andrei Sekretenko > >