> On Dec. 14, 2016, 1:34 a.m., Anand Mazumdar wrote: > > src/tests/containerizer/io_switchboard_tests.cpp, lines 91-115 > > <https://reviews.apache.org/r/54727/diff/1/?file=1583525#file1583525line91> > > > > hmm, I imagine us having a client for the Operator API in the future. > > If it has the same interface as the scheduler/executor library, it would be > > more suited if we rename this function to ease the transition in the future: > > > > ```cpp > > Future<http::Response> send( > > const Call& call, > > http::Connection connection); > > ``` > > > > Also, we would have helpers e.g., `createAttachOutputCall()` etc. > > similar to what we have for the Scheduler API (`createAcceptCall()`)
note that there are implicit assumptions about accept/content-type, request type and streaming responses in this helper, so not sure a `send(call, connection)` would be enough. i could add more params to this function to make it generic, but that seems like an overkill at this point. i'm basically trying to reduce the boiler plate code i need to write in tests, not necessarily a library function. i can add a TODO to make it generic once we have a few tests using this helper. - Vinod ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/54727/#review159088 ----------------------------------------------------------- On Dec. 14, 2016, 12:46 a.m., Vinod Kone wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/54727/ > ----------------------------------------------------------- > > (Updated Dec. 14, 2016, 12:46 a.m.) > > > Review request for mesos, Anand Mazumdar and Kevin Klues. > > > Repository: mesos > > > Description > ------- > > Pulled out some code into helpers that can be re-used in other tests. > I plan to use them in subsequent patches. > > > Diffs > ----- > > src/tests/containerizer/io_switchboard_tests.cpp > 5bd9dc4a776fe8a0d04ed31aa167f10c394984e6 > > Diff: https://reviews.apache.org/r/54727/diff/ > > > Testing > ------- > > make -j20 check GTEST_FILTER="*Switchboard*" MESOS_VERBOSE=1 > > > Thanks, > > Vinod Kone > >
