----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/65581/#review199414 -----------------------------------------------------------
src/tests/master_allocator_tests.cpp Line 175 (original), 177-178 (patched) <https://reviews.apache.org/r/65581/#comment279742> You definitely want to add `.WillRepeatedly(Return())` here. src/tests/master_allocator_tests.cpp Lines 184-186 (patched) <https://reviews.apache.org/r/65581/#comment279743> I'm not sure you need these lines. They ensure that a second registration attempt always happens, which is very important if we have two different agents and such registration attempt triggers a registration exepectation for the second agent. So, as a general pattern it might be useful, but technically in this test I don't see any value. Am I missing anything? - Alexander Rukletsov On Feb. 9, 2018, 2:28 a.m., Till Toenshoff wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/65581/ > ----------------------------------------------------------- > > (Updated Feb. 9, 2018, 2:28 a.m.) > > > Review request for mesos and Benjamin Bannier. > > > Bugs: MESOS-8463 > https://issues.apache.org/jira/browse/MESOS-8463 > > > Repository: mesos > > > Description > ------- > > Most of the allocator tests were expecting a single invocation of > 'AddSave' on the allocator when registering a slave. Due to the nature > of our slave registration backoff, a single slave possibly sends > mutiple registration requests in short succession. Any event closely > connected to a slave registration will therefor be possibly invoked > multiple times over the lifetime of such test. > We now allow multiple invocations of 'AddSlave'. This patch also > enhances the timing control by introducing a paused clock over the > slave registration phase of these tests. > > > Diffs > ----- > > src/tests/master_allocator_tests.cpp > e4a63836ba8cae7b9cf2fce9d46a844858749182 > > > Diff: https://reviews.apache.org/r/65581/diff/4/ > > > Testing > ------- > > make check && ./bin/mesos-tests.sh --gtest_filter="MasterAllocatorTest*" > --gtest_repeat=1000 --gtest_break_on_failure > > > Thanks, > > Till Toenshoff > >
