> On Feb. 9, 2016, 2:29 p.m., Guangya Liu wrote: > > src/tests/scheduler_tests.cpp, line 850 > > <https://reviews.apache.org/r/43321/diff/1/?file=1237111#file1237111line850> > > > > Does this still needed? > > haosdent huang wrote: > I think still need, we don't sure what would happend in `Shutdown()` in > the future. > > Guangya Liu wrote: > I raise this issue because I saw that some cases do not include > `Clock::resume();` while some cases do include, it is better add some > comments here to clarify why does `Clock::resume();` is needed here. > > haosdent huang wrote: > Usually we call `Clock::resume()` if we don't want to pause the Clock > after we `Clock::pause` and `Clock::advance`.
I also noticed some of the tests call `Clock::resume()` while others don't. The only thing I have encoutered is if there is a task left running at the end of the test, wihtout a call to `Clock::resume()` the test would timeout and fail. In short, I guess it's no harm to keep it here before there is a general guideline for the pattern. - Shuai ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/43321/#review118391 ----------------------------------------------------------- On Feb. 8, 2016, 4:20 a.m., Shuai Lin wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/43321/ > ----------------------------------------------------------- > > (Updated Feb. 8, 2016, 4:20 a.m.) > > > Review request for mesos and Alexander Rukletsov. > > > Bugs: MESOS-4175 > https://issues.apache.org/jira/browse/MESOS-4175 > > > Repository: mesos > > > Description > ------- > > Speeded up SchedulerTest.Decline by advancing the clock. > > > Diffs > ----- > > src/tests/scheduler_tests.cpp 4e2db2ac40c59b9b9a97cd214b3cd1e727a4f0ad > > Diff: https://reviews.apache.org/r/43321/diff/ > > > Testing > ------- > > sudo make check -j2 GTEST_FILTER='ContentType/SchedulerTest.Decline/* > > ```sh > [ RUN ] ContentType/SchedulerTest.Decline/0 > [ OK ] ContentType/SchedulerTest.Decline/0 (114 ms) > [ RUN ] ContentType/SchedulerTest.Decline/1 > [ OK ] ContentType/SchedulerTest.Decline/1 (98 ms) > ``` > > > Thanks, > > Shuai Lin > >
