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 41962: Logger Module: Add tests for module recovery after agent failover.
Date Thu, 07 Jan 2016 22:49:39 GMT


> On Jan. 6, 2016, 11:32 a.m., Jojy Varghese wrote:
> > src/tests/container_logger_tests.cpp, line 95
> > <https://reviews.apache.org/r/41962/diff/1/?file=1183514#file1183514line95>
> >
> >     What is the ownership semantics of this pointer? Here and other places.

Other than the `Docker` object (owned by containerizer and test), all these pointers are owned
by the `Containerizer` object.


> On Jan. 6, 2016, 11:32 a.m., Jojy Varghese wrote:
> > src/tests/container_logger_tests.cpp, line 158
> > <https://reviews.apache.org/r/41962/diff/1/?file=1183514#file1183514line158>
> >
> >     Can we have this as :
> >     
> >     ``` 
> >     Shared<Docker> docker(new MockDocker(...)); 
> >     
> >     ```

The trade-off (style-wise) is that later in the test, we'd need to do:
```
EXPECT_CALL((MockDocker *) docker.get(), ps(_, _))
  .WillOnce(Return(containers));
```

And I'm not really thrilled about that cast.


- Joseph


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


On Jan. 5, 2016, 6:19 p.m., Joseph Wu wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/41962/
> -----------------------------------------------------------
> 
> (Updated Jan. 5, 2016, 6:19 p.m.)
> 
> 
> Review request for mesos, Benjamin Hindman, Gilbert Song, Artem Harutyunyan, Jie Yu,
and Timothy Chen.
> 
> 
> Bugs: MESOS-4150
>     https://issues.apache.org/jira/browse/MESOS-4150
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Adds two heavily-mocked tests for the Mesos containerizer and Docker containerizer. 
Each checks that `ContainerLogger::recover` is called during `Containerizer::recover`.
> 
> 
> Diffs
> -----
> 
>   src/tests/container_logger_tests.cpp c6b2e597517c74a55649287dc5ae5a3115f9a640 
>   src/tests/mesos.hpp a4811b0d8dee33ff2ca4968f532ce64b7ea95249 
>   src/tests/mesos.cpp f4b0f82449c4b6a2b4b7b7f14518714485d5a13a 
> 
> Diff: https://reviews.apache.org/r/41962/diff/
> 
> 
> Testing
> -------
> 
> make (OSX & Centos7)
> 
> Tests are run in the next review.
> 
> 
> Thanks,
> 
> Joseph Wu
> 
>


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