> On April 19, 2016, 3:03 p.m., haosdent huang wrote:
> > 3rdparty/libprocess/3rdparty/stout/tests/os_tests.cpp, line 976
> > <https://reviews.apache.org/r/45326/diff/6/?file=1350574#file1350574line976>
> >
> >     Should `EXPECT_SOME` here?
> 
> Guangya Liu wrote:
>     Can you please show more detail for why use `EXPECT_SOME` here?

`ASSERT` would abort the test while `EXPECT` would continue to run following 
code. I think we usually use `ASSERT` when something block the test. e.g. 
`ASSERT_SOME(master);`. And usually use `EXPECT` at those thing we want to test 
in the test cases. e.g. `EXPECT_CALL(...`.


> On April 19, 2016, 3:03 p.m., haosdent huang wrote:
> > 3rdparty/libprocess/3rdparty/stout/tests/os_tests.cpp, line 975
> > <https://reviews.apache.org/r/45326/diff/6/?file=1350574#file1350574line975>
> >
> >     Do we need test the priority here? When a binary exists in different 
> > folders at the same time.
> 
> Guangya Liu wrote:
>     I think that as long as the binary can be found should be good enough, 
> why need care the priority here?

Let me describe it in another way. Suppose `PATH` is `/usr/bin:/bin`, and `bar` 
exists in both `/usr/bin/bar` and `/bin/bar`. Are we we always guarantee that 
take the first one in `os::which()`? Or add comment about the priority?


- haosdent


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


On April 19, 2016, 2:56 p.m., Guangya Liu wrote:
> 
> -----------------------------------------------------------
> This is an automatically generated e-mail. To reply, visit:
> https://reviews.apache.org/r/45326/
> -----------------------------------------------------------
> 
> (Updated April 19, 2016, 2:56 p.m.)
> 
> 
> Review request for mesos, David vonThenen, Gilbert Song, haosdent huang, and 
> Jie Yu.
> 
> 
> Bugs: MESOS-4576
>     https://issues.apache.org/jira/browse/MESOS-4576
> 
> 
> Repository: mesos
> 
> 
> Description
> -------
> 
> Implemented os::which().
> 
> 
> Diffs
> -----
> 
>   3rdparty/libprocess/3rdparty/stout/include/stout/posix/os.hpp 
> dfe4eab2d812ef807c7416ac205573d55383c4ee 
>   3rdparty/libprocess/3rdparty/stout/tests/os_tests.cpp 
> 9bd34c7508cd813c5de18028956f6a740997c266 
> 
> Diff: https://reviews.apache.org/r/45326/diff/
> 
> 
> Testing
> -------
> 
> make
> make check
> 
> [ RUN      ] OsTest.Which
> [       OK ] OsTest.Which (0 ms)
> 
> 
> Thanks,
> 
> Guangya Liu
> 
>

Reply via email to