> On Feb. 23, 2017, 9:21 a.m., Benjamin Mahler wrote: > > src/tests/master_tests.cpp, lines 6704-6705 > > <https://reviews.apache.org/r/56941/diff/1/?file=1642690#file1642690line6704> > > > > Why did you need a mock executor and test containerizer? Seems to me > > this can be simplified by just running a sleep task with no mocking? > > > > E.g. > > > > ``` > > TaskInfo task = createTask(offers1.get()[0], "sleep 1000"); > > ``` > > > > You can find examples with: > > > > ``` > > $ grep -R -i sleep src/test > > ```
I'm using a `mock executor` instead of `command executor` here so that it could have some resources, and we can inspect `allocation_info`. I'm not sure how to do that with `sleep`... > On Feb. 23, 2017, 9:21 a.m., Benjamin Mahler wrote: > > src/tests/master_tests.cpp, line 6783 > > <https://reviews.apache.org/r/56941/diff/1/?file=1642690#file1642690line6783> > > > > Is this flaky? Looking at the agent source, I believe this has to be > > `slaveFlags.registration_backoff_factor * 2`, no? Good point! And I think it should advance *one* `registration_backoff_factor` and *one* `authentication_backoff_factor`, like https://github.com/apache/mesos/blob/master/src/tests/api_tests.cpp#L3577-L3579 - Jay ----------------------------------------------------------- This is an automatically generated e-mail. To reply, visit: https://reviews.apache.org/r/56941/#review166458 ----------------------------------------------------------- On Feb. 23, 2017, 1:43 a.m., Jay Guo wrote: > > ----------------------------------------------------------- > This is an automatically generated e-mail. To reply, visit: > https://reviews.apache.org/r/56941/ > ----------------------------------------------------------- > > (Updated Feb. 23, 2017, 1:43 a.m.) > > > Review request for mesos, Benjamin Bannier, Benjamin Mahler, Guangya Liu, and > Michael Park. > > > Bugs: MESOS-7063 > https://issues.apache.org/jira/browse/MESOS-7063 > > > Repository: mesos > > > Description > ------- > > When a non-MULTI_ROLE agent with running tasks re-registers, master > should inject allocation roles for tasks/executors sent during > re-registration. > > > Diffs > ----- > > src/tests/master_tests.cpp 357a9a47ef87be6cbc4256d8afabe63cd41b1ea1 > > Diff: https://reviews.apache.org/r/56941/diff/ > > > Testing > ------- > > make check > > > Thanks, > > Jay Guo > >
