mesos-reviews mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Joseph Wu <jos...@mesosphere.io>
Subject Re: Review Request 69178: Fixed test `MasterTestPrePostReservationRefinement.LaunchGroup`.
Date Fri, 26 Oct 2018 22:30:45 GMT

-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
https://reviews.apache.org/r/69178/#review210112
-----------------------------------------------------------




src/tests/master_tests.cpp
Lines 9562-9566 (original), 9562-9566 (patched)
<https://reviews.apache.org/r/69178/#comment294745>

    Let's do this instead:
    ```
      testing::Sequence updateSequence;
      Future<v1::scheduler::Event::Update> startingUpdate;
      Future<v1::scheduler::Event::Update> runningUpdate;
    
      EXPECT_CALL(
          *scheduler,
          update(_, AllOf(
              TaskStatusUpdateTaskIdEq(taskInfo),
              TaskStatusUpdateStateEq(v1::TASK_STARTING))))
        .InSequence(updateSequence)
        .WillOnce(DoAll(
            FutureArg<1>(&startingUpdate), 
            v1::scheduler::SendAcknowledge(frameworkId, agentId)));
    
      EXPECT_CALL(
          *scheduler,
          update(_, AllOf(
              TaskStatusUpdateTaskIdEq(taskInfo),
              TaskStatusUpdateStateEq(v1::TASK_RUNNING))))
        .InSequence(updateSequence)
        .WillOnce(DoAll(
            FutureArg<1>(&runningUpdate),
            v1::scheduler::SendAcknowledge(frameworkId, agentId));
    ```



src/tests/master_tests.cpp
Lines 9588-9598 (original), 9588-9614 (patched)
<https://reviews.apache.org/r/69178/#comment294747>

    Given the above suggestion, this can be replaced with:
    ```
    AWAIT_READY(startingUpdate);
    AWAIT_READY(runningUpdate);
    ```


- Joseph Wu


On Oct. 25, 2018, 4:11 p.m., Meng Zhu wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/69178/
> -----------------------------------------------------------
> 
> (Updated Oct. 25, 2018, 4:11 p.m.)
> 
> 
> Review request for mesos and Benno Evers.
> 
> 
> Bugs: MESOS-9079
>     https://issues.apache.org/jira/browse/MESOS-9079
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Added the missing scheduler acknowledgment calls so that the
> two expected task status updates can be delivered.
> 
> 
> Diffs
> -----
> 
>   src/tests/master_tests.cpp 1db8ed7d81acbcd8bad4b7ca77c501d1d99cc135 
> 
> 
> Diff: https://reviews.apache.org/r/69178/diff/1/
> 
> 
> Testing
> -------
> 
> run `MasterTestPrePostReservationRefinement.LaunchGroup` continously without failure
> 
> 
> Thanks,
> 
> Meng Zhu
> 
>


Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message